This repository has been archived by the owner on Apr 7, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Ex-3.por
57 lines (48 loc) · 1.33 KB
/
Ex-3.por
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
programa
{
inteiro n1, n2 , n3
funcao inicio()
{
escreva("Digite o primeiro número: ")
leia(n1)
limpa()
escreva("Digite o primeiro segundo: ")
leia(n2)
limpa()
escreva("Digite o primeiro terceiro: ")
leia(n3)
limpa()
se((n1 == n2) e (n1 == n3) e (n2 == n3) ){
escreva("Os valores são todos iguais.")
}
se((n1 < n2) e (n2 < n3) e (n3 > n1) e (n3 > n2)){
escreva("O máior valor é ", n3)
}
se( (n1 < n2 ) e (n1 < n3) e (n2 > n1) e (n2 > n3)){
escreva("O máior valor é ", n2)
}
se((n1 > n2) e (n1 < n3) e (n2 < n3) e (n3 > n1)){
escreva("O máior valor é ", n3)
}
se((n3 < n1) e (n3 < n2) e (n2 > n3) e (n2 > n1)){
escreva("O máior valor é ", n2)
}
se((n3 < n1) e (n3 < n2) e (n2 < n1) e (n2 > n3)){
escreva("O máior valor é ", n1)
}
se((n1 > n2) e (n1 > n2) e (n2 < n3) e (n3 < n1)) {
escreva("O máior valor é ", n1)
}
}
}
/* $$$ Portugol Studio $$$
*
* Esta seção do arquivo guarda informações do Portugol Studio.
* Você pode apagá-la se estiver utilizando outro editor.
*
* @POSICAO-CURSOR = 254;
* @PONTOS-DE-PARADA = ;
* @SIMBOLOS-INSPECIONADOS = ;
* @FILTRO-ARVORE-TIPOS-DE-DADO = inteiro, real, logico, cadeia, caracter, vazio;
* @FILTRO-ARVORE-TIPOS-DE-SIMBOLO = variavel, vetor, matriz, funcao;
*/