AgentTadpole

Answers - Java Int to Float converter

Jan 7th, 2014
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.23 KB | None | 0 0
  1. public class Main {
  2.     public float returnFloat(int a) {
  3.         return a;
  4.     }
  5.    
  6.     public static void main(String[] args) {
  7.         Main main = new Main();
  8.        
  9.         System.out.println(main.returnFloat(6));
  10.     }
  11. }
  12.  
  13. // Console output was "6.0"
Advertisement
Add Comment
Please, Sign In to add comment