Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

need help , in java on intellij please Open the file named Assignment.j java and amend it so that it solves the following problem: 1.

need help , in java on intellij please
image text in transcribed
Open the file named Assignment.j java and amend it so that it solves the following problem: 1. Declare an int variable called total with an initial value of 0 2. Declare an int variable called val1 which has no initial value 3. Declare an int variable called val2 which has no initial value 4. Assign 26 to the variable val1 5. Assign a value 1 bigger than the value of val1 to the variable val2 (you should no use the literal value 27). 6. Assign the sum of val1 and val2 to the variable total 7. Print out the values of val1, val2 and total so that each is separated by a comma Once you have successhisty run your program your output should be the same as the following: 26,27,53

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

c. What were you expected to do when you grew up?

Answered: 1 week ago

Question

4. Describe how cultural values influence communication.

Answered: 1 week ago

Question

3. Identify and describe nine cultural value orientations.

Answered: 1 week ago