Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Latest commit

 

History

History
History
67 lines (64 loc) · 1.66 KB

File metadata and controls

67 lines (64 loc) · 1.66 KB
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/*
:: SITE: eXcript.com
:: FB: fb.com/eXcript
:: URL:
:: NOME:
*/
public class Aula0052C {
// 4. Faca um programa que receba 10 valores inteiros e que indique: quantos são pares, quantos são impares, quantos são positivos e quantos são negativos.
// public static void main(String[] args) {
// int n1, n2, n3, n4, n5, n6, n7, n8, n9, n10;
//
// int n_pares=0, n_impares=0, n_pos=0, n_neg=0;
//
//
// System.out.println("digite o 1..º número inteiro");
//
// Console console = System.console();
// String input = console.readLine("Enter input:");
//
// n1 = Integer.valueOf(input);
//
// if (n1 % 2 == 0)
// n_pares++;
// else
// n_impares++;
//
// if (n1 > 0)
// n_pos++;
// else
// n_neg++;
//
// System.out.println("digite o 2.º número inteiro");
// System.out.println(n2);
//
// if (n2 % 2 == 0)
// n_pares++;
// else
// n_impares++;
//
// if (n2 > 0)
// n_pos++;
// else
// n_neg++;
//
// System.out.println("digite o 3.º número inteiro");
// System.out.println(n3);
//
// if (n3 % 2 == 0)
// n_pares++;
// else
// n_impares++;
//
// if (n3 > 0)
// n_pos++;
// else
// n_neg++;
//
// System.out.println("Resultados\n");
// System.out.printf(" %d números pares\n", n_pares);
// System.out.printf(" %d números impares\n", n_impares);
// System.out.printf(" %d números positivos\n", n_pos);
// System.out.printf(" %d números negativos\n", n_neg);
// }
}
Morty Proxy This is a proxified and sanitized view of the page, visit original site.