inital commit
This commit is contained in:
parent
35c21ca554
commit
ae0b3725a3
16
110A Nearly Lucky Number/110A.cpp
Normal file
16
110A Nearly Lucky Number/110A.cpp
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
#include<bits/stdc++.h>
|
||||||
|
using namespace std;
|
||||||
|
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
long long n;
|
||||||
|
int count=0;
|
||||||
|
cin>>n;
|
||||||
|
while(n!=0)
|
||||||
|
{
|
||||||
|
if(n%10==4 || n%10==7) count++;
|
||||||
|
n=n/10;
|
||||||
|
}
|
||||||
|
if(count==4 || count==7) cout<<"YES"<<endl;
|
||||||
|
else cout<<"NO"<<endl;
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user