1 #include<bits/stdc++.h> 2 using namespace std; 3 int main() 4 { 5 string s; 6 int ant=0; 7 cin>>s; 8 for(int i=0;i<s.length();i++) 9 { 10 ant*=10; 11 ant+=s[i]-‘0‘; 12 ant%=4; 13 } 14 if(ant==0) 15 cout<<4<<endl; 16 else 17 cout<<0<<endl; 18 }
时间: 2024-10-09 19:46:43