标签:for iostream include clu bsp div ++ har turn
水题。
#include"iostream" using namespace std; int main() { string str1,str2; char da,db; int pa = 0,pb = 0; cin>>str1>>da>>str2>>db; for(int i = 0; i < str1.length(); ++i) if(str1[i] == da) { pa = pa*10+da-‘0‘; } for(int i = 0; i < str2.length(); ++i) if(str2[i] == db) { pb = pb*10+db-‘0‘; } cout<<pa+pb; return 0; }
标签:for iostream include clu bsp div ++ har turn
原文地址:https://www.cnblogs.com/keep23456/p/12316359.html