Created
May 4, 2013 12:49
-
-
Save jimmy087/5517411 to your computer and use it in GitHub Desktop.
Conversion of kilogram to pounds
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Coversion of kilograms to pounds. | |
| public class Exercise4_5 { | |
| public static void main (String[] args){ | |
| System.out.println("Kilograms Pounds Pounds Kilograms"); | |
| System.out.println("--------------------------------------------------"); | |
| int kilograms = 1; | |
| int pounds = 20; | |
| int count = 1; | |
| while (count <= 100 ) { | |
| System.out.println(kilograms + " " + kilograms * 1.609 + " " + pounds + " " + pounds / 1.609); | |
| count++; | |
| kilograms += 2; | |
| pounds += 5; | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment