Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Function facpremier (n:Integer): String;
- Var
- i: Integer;
- ch: String;
- x: String;
- Begin
- i := 2;
- ch := '';
- Repeat
- If n Mod i = 0 Then
- Begin
- Str (i,x);
- ch := ch+x+'.';
- n := n Div i;
- End
- Else
- i := i+1;
- Until n=1;
- Delete (ch,Length(ch),1);
- facpremier := ch;
- End;
Advertisement
Add Comment
Please, Sign In to add comment