Run ID:82338

提交时间:2024-07-13 10:50:04

#include<bits/stdc++.h> using namespace std; char s[1000]; int main(){ int cl = 0,n = 0,sl =0; cin.getline(s,1000); sl = strlen(s); for(int i =0;i < sl;i++){ if(s[i] == ' '){ cout << cl << ","; cl =0; }else{ cl++; } } cout << n; return 0; }