subject

Suppose you write the following program that prompts the user to enter the current year tuition and finds out how many years the tuition will be doubled. there is an error in the highlighted line. fix it. you don't need to write the complete new program, just circle the affected code and replace it with the new code.   import java. util. scanner; public class test { public static void main( string[] args) { scanner input = new scanner(system. in); system. out. print("enter the current year tuition: "); double tuition = input. nextdouble();   int year = 0;   while (tuition < 2 * tuition) { tuition = tuition * 1.07; year++; }   system. out. println("tuition will be doubled in " + year + " years"); system. out. printf("tuition will be $%.2f in %1d years ", tuition, year);   } }     fyi: highlighted line is [while (tuition < 2 * tuition)]

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 19:30
Asalesman at a high end computer security firm want to sell you a proactive cover for your passport, which contains an rfid tag inside storing your sensitive information. the salesperson's solution cost only $79.99 and protects your passport from being read via radio waves while it is in your pocket. explain how you can achieve the same thing under $3.00
Answers: 3
question
Computers and Technology, 22.06.2019 08:10
Ihave a music player on my phone. i can buy songs, add them to playlists and play them. obviously it would be redundant to store each song in each playlist; each playlist is just a list of pointers to the songs. for this lab you will simulate this behavior. your program will need to have options to: add songs to the system library (you will store the text of the first line of the song, rather than the audio) add playlists add songs to a playlist list playlists play a playlist list all of the songs in the library with a count of how many times each song has been played remove a song from a playlist remove a playlist remove a song from the library (and thus from all playlists that contain it) note that we will not be checking many error cases. in real programming this would be bad, you should usually try to recognize and respond to as many types of errors as you can. in the context of class we are trying to acquaint you with as many concepts as possible, so for the sake of educational efficiency we will not be checking most errors in this lab, you may assume that your user provides correct input. you may add all appropriate error testing if you wish, but we will not be testing for it.
Answers: 2
question
Computers and Technology, 22.06.2019 17:00
Aisha has finished working on a word processing document that contains 15 pages. she has added some special elements in the first three pages, page 9 and 10, and page 15 from the document. she wants to print only these pages to see how they look. which option is the correct way to represent (in the print dialog box) the pages that aisha wants to print
Answers: 3
question
Computers and Technology, 22.06.2019 21:00
Which of these is most responsible for differences between the twentieth century to the twenty-first century?
Answers: 2
You know the right answer?
Suppose you write the following program that prompts the user to enter the current year tuition and...
Questions
question
Mathematics, 07.07.2019 16:30
question
Mathematics, 07.07.2019 16:30
question
Mathematics, 07.07.2019 16:30
question
Social Studies, 07.07.2019 16:30
question
Mathematics, 07.07.2019 16:30
Questions on the website: 13722367