Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int notOptimisednum = 1;
- //this isn't very optimised
- byte veryOptimisednum = 1;
- //this is very optimised
- //bytes can only be between -128 and 127 so if you have to go further than that... then use:
- short moreOptimisednum = 1000;
- //this is more optimised
- System.out.println(notOptimisednum);
- System.out.println(veryOptimisednum);
- System.out.println(moreOptimisednum);
- //just to print the values out now
Add Comment
Please, Sign In to add comment