repl.it
@PacoTaco/

JAVA DATA TYPE

Java

No description

fork
loading
Files
  • Main.java
  • jdt.ls-java-project
Main.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
class Main {
  public static void main(String[] args) {
    System.out.println("Hello world!");
    char letter = 'z';
    //single '' are for one letter
    //double "" are for sentences
    System.out.println(letter);
    int a = 5;
    System.out.println(a);
    String name = "Paco";
    System.out.println(name);
    double b = 5.5;
    System.out.println(b);
    float c = 7.7f;
    System.out.println(c);
    long d = 70000;
    System.out.println(d);
    if(a<10){
      System.out.println("a is less than 10");
    }
  }
}
Fetching token
?