Created
March 15, 2013 13:02
-
-
Save FernandaBernardo/5169742 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Scanner; | |
public class OlaMundo{ | |
public static void main (String [] args) | |
{ | |
Scanner sc = new Scanner (System.in); | |
System.out.println ("Digite um numero que voce deseja somar"); | |
int x = sc.nextInt(); | |
System.out.println ("Digite outro numero que voce deseja somar"); | |
int y = sc.nextInt(); | |
System.out.println ("O resultado da soma eh " + (x+y)); | |
//int corinthians = 1910; | |
/*int corinthians = sc.nextInt(); | |
System.out.println ("O Corinthians foi fundado em " + corinthians | |
+". Entretanto, o Palmeiras e o melhor \n" ); | |
int macarrao = corinthians % 2; | |
if (macarrao == 1) | |
{ | |
System.out.println("o numero" + corinthians + "e impar"); | |
} | |
else{ | |
System.out.println("ela nao deixou copiar, to de mau, mas e par u.u"); | |
} | |
System.out.println("Voce eh bixo?"); | |
String bixo = sc.next(); | |
if (bixo.equals ("sim")) System.out.println ("Parabens"); | |
else if (bixo.equals ("nao")) System.out.println ("Rodou"); | |
else System.out.println("faz cursinho de novo"); | |
*/ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment