Răspunsuri

Cel mai inteligent răspuns!
2014-10-20T17:11:04+03:00
# include<iostream>
using namespace std;
int main()
{
    unsigned n,ultimacifra,nr=0;
    cin>>n;
    while(n!=0)
    {
        ultimacifra = n%10;
        if(ultimacifra%3==0)
           nr++;
        n/=10;
    }
    cout<<nr;
    return 0;
}