Programas foxpro

Páginas: 2 (373 palabras) Publicado: 10 de febrero de 2011
Programa de las tablas
program tablas;
uses wincrt;
var
tabla,n,r:integer;
begin
clrscr;
for tabla:= 1 to 10 do
begin
writeln('tabla del:=', tabla);
for n:= 1 to 10 do
begin
r:= tabla*n;writeln( tabla,'*',n,'=',r);
end;
readln;
end;
end.

Programa del menú de opción
program menu;
uses wincrt;
var
a,b,suma,resta,multiplicacion,division,raiz:real;
opcion:integer;
beginclrscr;
writeln( '1. Suma');
writeln(' 2. Resta');
writeln(' 3. Raiz');
writeln(' 4. Multiplicacion');
writeln(' 5. Division');
writeln(' 6. Salir');
write (' ingrese opcion'); readln(opcion);if opcion= 1 then
begin
write( ' ingrese primer numero'); readln (a);
write( ' ingrese segundo numero'); readln (b);
suma:= a+b;
writeln(' la suma es ',suma:10:2);
end;
if opcion= 2 thenbegin
write( ' ingrese primer numero'); readln (a);
write( ' ingrese segundo numero'); readln (b);
resta:= a-b;
writeln(' la resta es ',resta:10:2);
end;
if opcion= 3 then
begin
write ('ingreseprimer numero'); readln (a);
raiz:= sqrt(a);
writeln('la raiz es',raiz:10:2)
end;
if opcion= 4 then
begin
write (' ingrese primer numero'); readln (a);
write (' ingrese segundo numero'); readln(b);
multiplicacion:= a*b;
writeln( ' la multi es', multiplicacion:10:2);
end;
if opcion= 5 then
begin
write (' ingrese primer numero'); readln (a);
write (' ingrese segundo numero'); readln(b);
division:= a/b;
writeln( ' la multi es', multiplicacion:10:2);
end;
if opcion = 6 then
begin
writeln ('Salir');
end;
end.

Programa del producto
program producto;
uses wincrt;
vara:string;
b,c: integer;
d,e,f: real;
begin
clrscr;
write('ingrese producto'); readln (a);
write('ingrese cantidad'); readln (b);
write('ingrese precio'); readln (c);
d:= b*c;
e:= c*0.12;
f:=c/1.12;
writeln(' el total es ',d:10:2);
writeln(' el iva es',e:10:2);
writeln(' el precio sin iva es',f:10:2);
end.

Programa del promedio

uses wincrt;
var
a,b,c,d,e:real;
begin
clrscr;...
Leer documento completo

Regístrate para leer el documento completo.

Estos documentos también te pueden resultar útiles

  • hacer un programa en foxpro
  • Visual FoxPro manual del programador
  • Manual Programador Visual Foxpro
  • Plantematico de un programa de visual foxpro
  • FoxPro
  • Foxpro
  • Foxpro
  • Foxpro

Conviértase en miembro formal de Buenas Tareas

INSCRÍBETE - ES GRATIS