Difference between revisions of "Java: Soma de dois números inteiros"
From AdonaiMedrado.Pro.Br
m (moved Java: Somador to Java: Soma de dois números) |
|||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
<code lang=java> | <code lang=java> | ||
+ | import java.util.Scanner; | ||
+ | |||
public class Somador | public class Somador | ||
{ | { | ||
public static void main(String[] args) | public static void main(String[] args) | ||
{ | { | ||
− | + | Scanner s = new Scanner(System.in); | |
− | + | System.out.println(s.nextInt()+s.nextInt()); | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
} | } | ||
} | } | ||
</code> | </code> |