Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class game
- {
- int homeScore, awayScore;
- String homeName, awayName;
- public game(String hn, String an, int hs, int as)
- {
- homeScore = hs; awayScore = as;
- homeName = hn; awayName = an;
- }
- public void print()
- {
- System.out.printf("%-15s %-2s%20s%10s", homeName, homeScore, awayName,awayScore);
- System.out.println();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement