Uploaded by axorotxavfsizligi777

mustaqil talim

advertisement
#include <iostream>
#include <math.h>
using namespace std;
int main()
{
int a,s=0,i=1;
bool b=true;
cin>>a;
while(b){
s+=a/pow(5,i);
if(a/pow(5,i)==0){
b=false;
}i++;
}
cout<<s;
}
#include <iostream>
#include <math.h>
using namespace std;
int main()
{
int a,b,i=2;
cin>>a>>b;
b-=a;
while(b!=2*(a+1)){
a++;
b-=a;
i++;
}
cout<<i;
}
#include <iostream>
#include <math.h>
using namespace std;
int main()
{
string a;
cin>>a;
for(int i=a.length();i>1;i++){
cout<<a[i-2];
break;
}
}
#include <iostream>
#include <math.h>
using namespace std;
int main()
{
int n,a ,b,c;
cin>>n;
a=n/(60*60*24);
n%=(60*60*24);
b=n/3600;
n%=3600;
c=n/60;
n%=60;
cout<<a<<" "<<b<<" "<<c<<" "<<n;
}
Download