#include <bits/stdc++.h>
using namespace std;
int n, t, st, sst;
string s, opr;
int main()
{
cin.tie(NULL)->sync_with_stdio(false);
cin>>n;
while (n--)
{
cin>>opr>>s;
if (opr.size()==7)
{
cout<<++t<<' '<<s<<'\n';
st=sst=0;
}
else if (opr.size()==10)
{
sst=0;
cout<<t<<'.'<<++st<<' '<<s<<'\n';
}
else
{
cout<<t<<'.'<<st<<'.'<<++sst<<' '<<s<<'\n';
}
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |