Programacion
VISUALICE LOS NÚMEROS DEL 1 AL 10
program visualrepeat;
uses crt;
var
c:byte;
begin
clrscr;
textcolor (2); write(' visualize los numeros del 1 al 10 ');writeln;writeln;writeln;
c:=1;
repeat
write( c:5);
c:=c+1;
until c=11;
readln
end.
VISUALICE LOS NÚMEROS DEL 1000 AL 500 EN FORMA DECRECIENTE DE DOS EN DOS.
program dosENdos;
uses crt;
varm:integer;
begin
clrscr; textcolor (4); gotoxy (55,2);
writeln( ' NUMEROS DEL 1000 al 500');
writeln;writeln;
textcolor(2);
m:=1000;
repeat
write (m:5);
m:=m-2;
until
m=498;
readlnend.
VISUALICE LOS NÚMEROS DEL 2000 AL 3000 DE 5 EN 5 EN FORMA DECRECIENTE
program cincodecreciente;
uses crt;
var
c:integer;
begin
clrscr;
textcolor (2); write(' visualize los numeros del2000 al 3000 en forma decreciente ');
writeln;writeln;writeln;
c:=3000;
repeat
write( c:5);
c:=c-5;
until c=1995;
readln
end.
VISUALICE LOS NÚMEROS DEL 0 AL 500 DE UNO EN UNO
programnumerosdelceroal500;
uses crt;
var
c:integer;
begin
clrscr;
textcolor (2); write(' visualize los numeros 0 al 500 de 1 en 1 ');
writeln;writeln;writeln;
c:=500;
repeat
write( c:5);c:=c+1;
until c=5001;
readln
end.
CALCULESE LA SUMA DE 10 CALIFICACIONES INTRODUCIDAS POR TECLADO. UTILIZE REPEAT.
program sumadecali;
uses crt;
varc,calf:byte;
suma :integer;
begin
clrscr;
c:=1;
calf:=0;
suma:=0;
repeat
writeln( ' escribe calificacion ');
readln(calf);writeln;
suma:=suma+calf;
c:=c+1;
writeln(' en la suma total es : ' , suma:2);
until
c=11;
readln;
end.
EL NUMERO LA SUMA, EL PROMEDIO DE LOS NÚMEROSPAR O IMPAR INTRODUCIDOS POR TECLADO.
program serie_par_impar ;
uses crt;
var
n,z,num,imp,par,spar,simp,c:integer;
begin
clrscr;
textcolor (8);write (' cuantos numeros incluye la serie:...
Regístrate para leer el documento completo.