Number check
Java Code
+ 0 likes
Please Register to submit score.
| Average Score | 1.4 (of 5 scores) |
| Date Added | Nov 20, 2008 |
| Last Updated | Nov 20, 2008 |
| Tags | bigger biggest check digit integer java number range script smaller smallest than |
Introduction

My first Java code!
I was getting a bit sick of mIRC seeing as it didn't have any practical uses in life. Although, this really doesn't serve any practical purpose either but I reckon it's a great start for only starting an hour ago. :P
I mainly posted it up here so that people can get an insight into Java. I have also added tons of comments so a user can *hopefully* follow the code and understand what it is doing. It's very basic, and something that might seem pointless, but it could be good for people just starting Java, ya never know.
The script will check by the two variables (you can change the values) and return information depending on which is bigger.
---How to use---
You'll need to open your Java compiler and paste the code in.
I CANNOT STRESS IT ENOUGH THAT YOU MUST KNOW WHAT YOU ARE DOING LOADING THIS. The filename MUST be Numbercheck.java. Otherwise, if it isn't, it will not work. And yes, it IS CASE SENSITIVE.
If you do not have a compiler and want to try this, I suggest getting JCreator. It's totally free and easy to use. http://www.jcreator.com/download.htm
If anyone knows how to do the $? equivalent in Java, please let me know! I want to make the user able to input the variable values.
Java Snippet:
Number check
Posted on Nov 20, 2008 3:40 pm
Posted on Nov 20, 2008 3:40 pm
Screenshot has been added.
Considering I have only been learning for an hour, I think I'm doing pretty well. =]
Considering I have only been learning for an hour, I think I'm doing pretty well. =]
Java Snippet:
Number check
Posted on Nov 20, 2008 3:48 pm
Posted on Nov 20, 2008 3:48 pm
You should have the user enter two numbers
Java Snippet:
Number check
Posted on Nov 20, 2008 3:56 pm
Posted on Nov 20, 2008 3:56 pm
That's what I said in the intro, lol
Still trying to figure out how you can do it.
Still trying to figure out how you can do it.
Java Snippet:
Number check
Posted on Nov 21, 2008 1:52 am
Posted on Nov 21, 2008 1:52 am
What's with the 1.4?
I know it's not that amazing and all but it's not either ripped or incomplete. =/
I know it's not that amazing and all but it's not either ripped or incomplete. =/
Java Snippet:
Number check
Posted on Apr 4, 2009 8:23 pm
Posted on Apr 4, 2009 8:23 pm
I think this would be it:
| Code: |
import java.util.Scanner; class keyboardinput { /** * Method main * * * @param args * */ public static void main(String[] args) { Scanner myScanner = new Scanner(System.in); int a,b; a = myScanner.nextInt(); b = myScanner.nextInt(); } } |








