QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#691106#7656. EszettVanLam#WA 0ms3832kbC++14622b2024-10-31 09:54:312024-10-31 09:54:31

Judging History

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

  • [2024-10-31 09:54:31]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3832kb
  • [2024-10-31 09:54:31]
  • 提交

answer

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

set<string> ans;
int used[100];
string s;

void Try(int id, string res)
{
	if(id >= s.size()) return;
	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: 3600kb

input:

AUFREISSEN

output:

aufreiBen
aufreissen

result:

ok correct

Test #2:

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

input:

MASSSTAB

output:

maBstab
masBtab
massstab

result:

ok correct

Test #3:

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

input:

EINDEUTIG

output:

eindeutig

result:

ok correct

Test #4:

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

input:

S

output:

s

result:

ok correct

Test #5:

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

input:

STRASSE

output:

straBe
strasse

result:

ok correct

Test #6:

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

input:

M

output:

m

result:

ok correct

Test #7:

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

input:

MZ

output:

mz

result:

ok correct

Test #8:

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

input:

SE

output:

se

result:

ok correct

Test #9:

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

input:

BS

output:

bs

result:

ok correct

Test #10:

score: -100
Wrong Answer
time: 0ms
memory: 3592kb

input:

SS

output:

ss

result:

wrong output format Unexpected end of file - token expected