Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

i need it in java programming public class Baseball { public static void main(String [] args) { int dodgers; int yankees; int orioles; Scanner scnr

i need it in java programming

public class Baseball { public static void main(String [] args) { int dodgers; int yankees; int orioles;

Scanner scnr = new Scanner(System.in); yankees = scnr.nextInt(); dodgers = scnr.nextInt(); orioles = scnr.nextInt();

System.out.print("the Yankees scored " + yankees + '', and''); System.out.print("Last night the Dodgers scored " + dodgers + '',''''); System.out.print("the Cubs scored " + cubs + ''.''); }

Ex: the If input is:

2 3 4 

the output is:

Last night the Dodgers scored 2, the Yankees scored 3, and the Cubs scored 4. 

End the last output with a newline.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions

Question

2. Outline the business case for a diverse workforce.

Answered: 1 week ago