Raptor:
Generate of Algorithm:
C++:
#include <iostream>
#include <string>
using namespace std;
int main()
{
string
raptor_prompt_variable_zzyz;
int n;
int a;
int b;
int c;
int d;
int p;
int q;
raptor_prompt_variable_zzyz ="masukkan bilangan = ";
cout <<
raptor_prompt_variable_zzyz << endl;
cin >> n;
if (n<1000)
{
a =n % 10;
b =n % 100;
q =(b-a)/10;
c =b-a;
d =n-(a+c);
p =d/100;
cout <<
a<<" satuan"<<" , "<<q<<"
puluhan"<<" , "<<p<<" ratusan"
<< endl; }
else
{
cout <<
"bilangan terlalu besar" << endl; }
system
("PAUSE");
return 0;
}
0 comments:
Post a Comment