ICT110_Exercices Part3.pptx - Exercise 1 Write IPO pseudocode algorithm and JAVA program to find the volume of a cylinder Where Volume= Pi radius radius

ICT110_Exercices Part3.pptx - Exercise 1 Write IPO...

This preview shows page 1 - 6 out of 11 pages.

Exercise 1 1 Write IPO , pseudocode , algorithm and JAVA program to find the volume of a cylinder. Where Volume= Pi * radius * radius * height
Image of page 1
Exercise 2 2 Write an ALGORITHM and a JAVA PROGRAM that will convert the temperature in Fahrenheit to the temperature in Celsius. Where T (°C) = ( T (°F) - 32) × 5/9
Image of page 2
Exercise 3 Write a java program that will input the wavelength of light and display the spectrum color based on the wavelength range. 3
Image of page 3
Exercise 4 - Calculator Write a java program that accepts 2 integer numbers and an operator { + - * / % }. The program should perform the operation with the numbers and the operator and print the result. The program keep performing operations until the user input -1 as first operand’s value. If the operator entered is not valid, the program should display an error message. 4
Image of page 4
Exercise 5 Rewrite the following code by using switch statement. 5 char grade = input.next(); if ( grade == 'A' || grade == 'B' ) System. out .print( "Good work" ); else if ( grade == 'C' ) System. out .print( "Average work" ); else if ( grade == 'D' || grade == 'F' ) System. out .print( "Poor work" ); else System. out .print( "Not a valid letter grade" );
Image of page 5
Image of page 6

You've reached the end of your free preview.

Want to read all 11 pages?

  • Summer '20
  • Do while loop

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern

Stuck? We have tutors online 24/7 who can help you get unstuck.
A+ icon
Ask Expert Tutors You can ask You can ask You can ask (will expire )
Answers in as fast as 15 minutes