--AUTOR: Jose Luis VILLARIG GARCIA (V2975813) 472542@cepsz.unizar.es --FICHERO: Divisores.adb --FECHA: Octubre-Noviembre 1999 --Modidicado por: --Fecha modificacion: --Descripcion: Este programa halla los divisores de un numero. --Lo hice como paso previo al de los numeros perfectos. with text_io, Ada.integer_text_io; use text_io, Ada.integer_text_io; procedure divisores is -- declaracion de constantes y variables n: integer; i: integer; begin put ("Introduce el numero: "); get(n); put ("Sus divisores son: "); i := 1; while i < n loop If n mod i = 0 THEN -- si n mod i es 0 sera divisor put(i,0); put(", "); End if; i := i+1; end loop; put (n,0); put ("."); end divisores;