Subdomain Posts
PHP | 6 hours ago
PHP | 6 hours ago
PHP | 11 hours ago
PHP | 13 hours ago
PHP | 13 hours ago
PHP | 14 hours ago
PHP | 15 hours ago
PHP | 17 hours ago
PHP | 21 hours ago
PHP | 21 hours ago
Recent Posts
None | 15 sec ago
None | 23 sec ago
None | 1 min ago
None | 3 min ago
None | 3 min ago
None | 4 min ago
JavaScript | 4 min ago
None | 4 min ago
Lua | 4 min ago
None | 4 min ago
Sitereport
Find cool info about any domain on the internet?
visit sitereport
Free Subdomains
Want a pastebin.com sub-domain for your community?
learn more...
What is pastebin?
Pastebin is a website that hosts all your text & code on dedicated servers for easy sharing.
learn more...
Learn a little bit about the new Pastebin.com on our help page. hide message
By Rodrigo F on the 30th of Jun 2009 11:30:53 AM Download | Raw | Embed | Report
  1. Procedimento Varrer;
  2. var
  3.   i: inteiro
  4.   NomesAlunos: String;
  5. inicio
  6.   NomesAlunos := '' // inicialização da variável
  7.   Para i:= 0 a 30 faça inicio
  8.     Se Notas[i] >= 4 e Notas[i] <= 5.9 entao
  9.       Se NomesAlunos = '' então
  10.          NomesAlunos := Nomes[i]
  11.       Senão
  12.          NomesAlunos := NomesAlunos + ', ' +  +  Nomes[i] // recebe ele mesmo e incrementa o nome no array  
  13.   fim;  
  14. fim;
  15.  
  16.  
  17. Lembrando que o preenchimento dos vetores já existem (ou seja já estão feitos)
  18.  
  19. Passo 7
  20.  
  21. procedimento Perc;
  22. var
  23.   ComVS, SemVS, i: Integer;
  24.   PercComVS, PercSemVS : Numeric;
  25. inicio
  26.   ComVS := 0;
  27.   SemVS := 0;
  28.   PercComVS := 0;
  29.   PercSemVS := 0;
  30.  
  31.   Para i:= 1 a 30 faça inicio
  32.     Se Notas[i] >= 6.0 entao  // testa quem passou direto
  33.       SemVS := SemVS + 1
  34.     Senão Se Notas[i] >= 4.0 e Notas[i] <= 5.9  entao
  35.       ComVS := ComVS + 1;
  36.   fim
  37.  
  38.   // Depois das varíveis calculadas, ele pegará o percentual (lembrando que são 30 alunos, nesse meu exemplo)
  39.   PercComVS := (ComVS / 30) * 100;
  40.   PercSemVS := (SemVS / 30) * 100;
  41.  
  42.   Mostra('Percentual Com Verificação: '+ PercComVS +'%');
  43.   Mostra('Percentual Sem Verificação: '+ PercSemVS +'%');
  44. fim;
  45.  
  46. fim
Submit a correction or amendment below. [ previous version ] | [ difference ] | Make A New Post
To highlight particular lines, prefix each line with @h@
Syntax highlighting:
Post expiration:
Post exposure:
Name / Title:
Email: