QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#691102#7656. EszettVanLam#RE 0ms3828kbC++14598b2024-10-31 09:52:462024-10-31 09:52:48

Judging History

你现在查看的是最新测评结果

  • [2024-10-31 09:52:48]
  • 评测
  • 测评结果:RE
  • 用时:0ms
  • 内存:3828kb
  • [2024-10-31 09:52:46]
  • 提交

answer

#include <bits/stdc++.h>
#define fastIO ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);
#define int long long
const int N = 1e6 +2;using namespace std;

set<string> ans;
string s;

void Try(int id, string res)
{
	if(id == s.size() - 1){
		ans.insert(res + s[id]);
		return;
	}
	if(s[id] == 's' && s[id + 1] == 's'){
		Try(id + 2, res + "B");
	}
	Try(id + 1, res + s[id]);
}


void solve(){
	cin >> s;
	for(char &x : s) x += 32;
	Try(0, "");
	for(auto x : ans) cout << x << endl;
}
signed main() {
	int T = 1;
//	cin >> T;
	while (T--) solve();
	
	return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 3608kb

input:

AUFREISSEN

output:

aufreiBen
aufreissen

result:

ok correct

Test #2:

score: 0
Accepted
time: 0ms
memory: 3600kb

input:

MASSSTAB

output:

maBstab
masBtab
massstab

result:

ok correct

Test #3:

score: 0
Accepted
time: 0ms
memory: 3820kb

input:

EINDEUTIG

output:

eindeutig

result:

ok correct

Test #4:

score: 0
Accepted
time: 0ms
memory: 3508kb

input:

S

output:

s

result:

ok correct

Test #5:

score: 0
Accepted
time: 0ms
memory: 3612kb

input:

STRASSE

output:

straBe
strasse

result:

ok correct

Test #6:

score: 0
Accepted
time: 0ms
memory: 3536kb

input:

M

output:

m

result:

ok correct

Test #7:

score: 0
Accepted
time: 0ms
memory: 3828kb

input:

MZ

output:

mz

result:

ok correct

Test #8:

score: 0
Accepted
time: 0ms
memory: 3816kb

input:

SE

output:

se

result:

ok correct

Test #9:

score: 0
Accepted
time: 0ms
memory: 3476kb

input:

BS

output:

bs

result:

ok correct

Test #10:

score: -100
Runtime Error

input:

SS

output:


result: