Advertisement
Guest User

Untitled

a guest
Jun 19th, 2017
133
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. public class Main {
  4.  
  5. static int toF(int t){
  6. return t*9/5+32;
  7. }
  8. public static void main(String[] args) {
  9. Scanner sc = new Scanner(System.in);
  10. String st=sc.nextLine();
  11. while (!st.equals("q")){
  12. int t=Integer.parseInt(st);
  13. System.out.println(toF(t));
  14. st=sc.nextLine();
  15. }
  16. }
  17.  
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement