s_id stringlengths 10 10 | p_id stringlengths 6 6 | u_id stringlengths 10 10 | date stringlengths 10 10 | language stringclasses 1
value | original_language stringclasses 11
values | filename_ext stringclasses 1
value | status stringclasses 1
value | cpu_time int64 0 100 | memory stringlengths 4 6 | code_size int64 15 14.7k | code stringlengths 15 14.7k | problem_id stringlengths 6 6 | problem_description stringlengths 358 9.83k | input stringlengths 2 4.87k | output stringclasses 807
values | __index_level_0__ int64 1.1k 1.22M |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
s751752658 | p04030 | u255280439 | 1542309331 | Python | Python (3.4.3) | py | Accepted | 39 | 4692 | 3,158 | import sys
import math
import collections
import itertools
import array
import inspect
# Set max recursion limit
sys.setrecursionlimit(1000000)
# Debug output
def chkprint(*args):
names = {
id(v): k
for k, v in inspect.currentframe().f_back.f_locals.items()
}
print(', '.join(
name... | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,181 |
s033839913 | p04030 | u236127431 | 1541993364 | Python | Python (3.4.3) | py | Accepted | 18 | 3060 | 154 | S=input()
L=""
n=0
while n<=len(S)-1:
if S[n]=="1":
L+="1"
elif S[n]=="0":
L+="0"
elif S[n]=="B" and L!="":
L=L[:-1]
n+=1
print(L) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,182 |
s212386640 | p04030 | u782098901 | 1541970118 | Python | Python (3.4.3) | py | Accepted | 18 | 2940 | 132 | st = input()
ans = ""
for s in st:
if s != "B":
ans += s
elif len(s):
ans = ans[:len(ans) - 1]
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,183 |
s226580610 | p04030 | u782098901 | 1541969188 | Python | Python (3.4.3) | py | Accepted | 19 | 2940 | 159 | S = input()
ans = ""
for s in S:
if s == "0":
ans += s
elif s == "1":
ans += s
else:
ans = ans[:len(ans) - 1]
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,184 |
s008606105 | p04030 | u432805419 | 1541908612 | Python | Python (3.4.3) | py | Accepted | 19 | 3060 | 215 | a = list(input())
b = []
for i in range(len(a)):
if a[i] == "0":
b.append("0")
elif a[i] == "1":
b.append("1")
elif a[i] == "B" and len(b) != 0:
b.pop()
else:
continue
print("".join(b)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,185 |
s903320477 | p04030 | u939552576 | 1541713186 | Python | Python (3.4.3) | py | Accepted | 18 | 2940 | 177 | s = input()
ans = ''
for x in s:
if x == 'B':
if len(ans) == 0:
continue
else:
ans = ans[:-1]
else:
ans += x
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,186 |
s786379329 | p04030 | u397531548 | 1541558827 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 117 | S=input()
L=""
for i in S:
if i=="B":
L=L[:-1]
elif i!="B":
L+=i
print(L) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,187 |
s665489500 | p04030 | u397531548 | 1541552183 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 117 | S=input()
L=""
for i in S:
if i=="B":
L=L[:-1]
elif i!="B":
L+=i
print(L) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,188 |
s652633352 | p04030 | u163449343 | 1541542717 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 110 | ans = ""
for key in input():
if key != "B":
ans += key
else:
ans = ans[:-1]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,189 |
s733047613 | p04030 | u386819480 | 1541475348 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 238 | ## ABC 043 b
s = list(input())
ans = []
for i in s:
if(i == '0' or i == '1'):
ans.append(i)
elif(i == 'B'):
if(len(ans) == 0):
continue
else:
ans.pop()
print(''.join(ans)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,190 |
s740427925 | p04030 | u063052907 | 1541431504 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 156 | # coding: utf-8
s = input()
ans = []
for a in s:
if a == "B":
if ans:
ans.pop()
else:
ans.append(a)
print("".join(ans)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,191 |
s721210225 | p04030 | u063052907 | 1541431325 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 125 | # coding: utf-8
s = input()
ans = ""
for a in s:
if a == "B":
ans = ans[:-1]
else:
ans+=a
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,192 |
s360453869 | p04030 | u063052907 | 1541431123 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 163 | # coding: utf-8
s = input()
ans = ""
for a in s:
if a == "0":
ans+="0"
elif a == "1":
ans+="1"
else:
ans = ans[:-1]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,193 |
s471995880 | p04030 | u432805419 | 1541394823 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 221 | a = list(input())
b = []
for i in range(len(a)):
if a[i] == "0":
b.append("0")
elif a[i] == "1":
b.append("1")
elif a[i] == "B":
if b == []:
b = []
else:
del b[-1]
print("".join(b)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,194 |
s601469080 | p04030 | u350997995 | 1541299422 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 140 | s = input()
A = []
moji = ''
for i in range(len(s)):
if s[i]=='B':
A = A[:-1]
else:
A.append(s[i])
moji = ''.join(A)
print(moji) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,195 |
s993756085 | p04030 | u943657163 | 1541268476 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 181 | ans = []
for s in list(input()):
if s == '0' or s == '1':
ans.append(s)
elif s == 'B':
if not ans:
continue
ans.pop()
print(''.join(ans)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,196 |
s175862263 | p04030 | u090225501 | 1541111222 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 113 | s = input()
m = []
for c in s:
if c == 'B':
if m:
m.pop()
else:
m.append(c)
print(''.join(m)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,197 |
s725860122 | p04030 | u637824361 | 1541104375 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 168 | s = input()
STR = []
for i in s:
if i != 'B':
STR.append(i)
elif STR.__len__() == 0:
continue
else:
STR.pop()
print("".join(STR))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,198 |
s106529121 | p04030 | u059727354 | 1541095561 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 112 | S = input()
ans = ""
for c in S:
if c == 'B':
ans = ans[0:-1]
else:
ans += c
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,199 |
s875243611 | p04030 | u294000907 | 1540873660 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 171 | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
s=input()
r=''
for i in range(0,len(s)):
if s[i]=='0' or s[i]=='1':
r=r+s[i]
elif len(s)>0:
r=r[:-1]
print(r)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,200 |
s571537091 | p04030 | u240793404 | 1540822289 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 130 | s = input()
ans = ""
for let in s:
if let == '0' or let == '1':
ans += let
else:
ans = ans[:-1]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,201 |
s558555388 | p04030 | u363407238 | 1540793725 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 156 | s = list(input())
ans = ''
for i in s:
if i == '0' or i == '1':
ans += i
elif i == 'B' and len(ans) != 0:
ans = ans[:-1]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,202 |
s016357591 | p04030 | u288601503 | 1540787020 | Python | Python (3.4.3) | py | Accepted | 16 | 3060 | 218 | s=list(input())
out=[]
for i in range(len(s)):
if s[i]=="B" and out==[]:
out=[]
elif s[i]=="B":
del(out[-1])
else:
out.append(s[i])
for i in range(len(out)):
print(out[i],end="") | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,203 |
s029316863 | p04030 | u733321071 | 1540752517 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 244 | # -*- coding: utf-8 -*-
s = list(input())
line = []
for w in s:
if w == '0':
line.append(w)
elif w == '1':
line.append(w)
elif w == 'B' and line:
line.pop()
for n in line:
print('{0}'.format(n), end='') | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,204 |
s341856887 | p04030 | u883048396 | 1540602778 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 176 | sS = input().rstrip()
a = []
for s in sS:
if s == "B":
if 0 < len(a):
#del a[-1]
a = a[:-1]
else:
a.append(s)
print("".join(a))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,205 |
s626751189 | p04030 | u883048396 | 1540602509 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 154 |
sS = input().rstrip()
a = []
for s in sS:
if s == "B":
if 0 < len(a):
del a[-1]
else:
a.append(s)
print("".join(a))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,206 |
s517904036 | p04030 | u754553095 | 1540496802 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 134 | a=list(input())
b=[]
for i in a:
if (i=="0") or (i=="1"):
b.append(i)
elif b!=[] :
b.pop(-1)
print("".join(b)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,207 |
s586753016 | p04030 | u295961023 | 1540203445 | Python | Python (3.4.3) | py | Accepted | 18 | 3060 | 279 | def main():
s = input()
ans = ''
for ch in s:
if ch == 'B' and len(ans) != 0:
ans = ans[:-1]
elif ch == 'B' and len(ans) == 0:
ans = ''
else:
ans += ch
print(ans)
if __name__ == '__main__':
main() | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,208 |
s695384594 | p04030 | u323680411 | 1540060255 | Python | Python (3.4.3) | py | Accepted | 19 | 2940 | 463 | from sys import stdin
def main():
s = next_str()
ans = []
for v in s:
if v == 'B':
if len(ans) != 0:
ans.pop()
else:
ans.append(v)
print("".join(ans))
def next_str():
result = ""
while True:
tmp = stdin.read(1)
if tmp.... | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,209 |
s529949126 | p04030 | u052332717 | 1539974770 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 223 | li = list(input())
string = ''
for item in li:
if item == '0':
string += '0'
elif item == '1':
string += '1'
else:
string = string[:-1]
print(string)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,210 |
s192245924 | p04030 | u832039789 | 1539901344 | Python | Python (3.4.3) | py | Accepted | 16 | 2940 | 151 | res = []
s = input()
for c in s:
if c=='B':
if len(res)!=0:
res = res[:-1]
else:
res.append(c)
print(''.join(res))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,211 |
s037449895 | p04030 | u094191970 | 1539888167 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 308 | S = input()
S_list = list(S)
answer = []
for S_num in S_list:
if S_num == '0':
answer.append('0')
elif S_num == '1':
answer.append('1')
elif not answer:
continue
else:
del answer[-1]
answer_honmono = ''
answer_honmono = ''.join(answer)
print(answer_honmono) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,212 |
s535239568 | p04030 | u546074985 | 1539699477 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 253 | l = [x for x in input()]
s = []
for x in l:
if x == "0":
s.append("0")
elif x == "1":
s.append("1")
elif x == "B":
try:
del s[-1]
except IndexError:
pass
print("".join(s)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,213 |
s106665007 | p04030 | u620480037 | 1539659984 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 269 | s=input()
ans=""
for i in range(len(s)):
if s[i]=="0":
ans=ans+"0"
elif s[i]=="1":
ans=ans+"1"
elif s[i]=="B":
if ans=="":
pass
else:
ans=ans[:len(ans)-1]
#print(str(ans))
print(str(ans))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,214 |
s252116274 | p04030 | u848647227 | 1539653919 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 154 | ar = list(input())
br = []
for a in ar:
if a == "0" or a == "1":
br.append(a)
else:
if len(br) != 0:
del br[len(br)-1]
print("".join(br)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,215 |
s786591831 | p04030 | u681150536 | 1539498729 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 243 | def main():
S = input()
answer = []
for s in S:
if s == "B":
if answer:
answer.pop()
else:
answer.append(s)
print(''.join(answer))
if __name__ == "__main__":
main()
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,216 |
s751153642 | p04030 | u459697504 | 1539393997 | Python | Python (3.4.3) | py | Accepted | 19 | 3188 | 538 | #! /usr/bin/python3
# バイナリハックイージー / Unhappy Hacking (ABC Edit)
"""
1. 先頭のB全部を消す
2.
"""
import re
test_mode = False
s = str(input())
for _ in range(10):
while s[0] == 'B':
s = s[1:]
if test_mode is True:
print(s)
s = re.sub('0B|1B', '', s)
if 'B' not in s:
print(... | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,217 |
s497996870 | p04030 | u595353654 | 1539387581 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 181 | # -*- coding: utf-8 -*-
from sys import stdin
s = stdin.readline().rstrip()
ans = ""
for i in range(len(s)):
ans += s[i]
if s[i] == "B":
ans = ans[:-2]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,218 |
s518516131 | p04030 | u138486156 | 1539234366 | Python | Python (3.4.3) | py | Accepted | 17 | 3064 | 152 | s = input()
ans = ""
for c in s:
if c == "1":
ans += "1"
elif c == "0":
ans += "0"
else:
ans = ans[:-1]
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,219 |
s912158950 | p04030 | u233152254 | 1538968692 | Python | Python (3.4.3) | py | Accepted | 16 | 2940 | 154 | S = input()
ans = ''
for c in S:
if c == '0' or c == '1':
ans += c
else:
if ans == '': continue
ans = ans[:-1]
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,220 |
s678948008 | p04030 | u233152254 | 1538968639 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 182 | S = input()
ans = ''
for c in S:
if c == '0':
ans += '0'
elif c == '1':
ans += '1'
else:
if ans == '': continue
ans = ans[:-1]
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,221 |
s392619682 | p04030 | u320325426 | 1538868900 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 95 | s = input()
r = ""
for i in s:
if i != "B":
r += i
if i == "B":
r = r[:-1]
print(r) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,222 |
s499748810 | p04030 | u513081876 | 1538855116 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 144 | s = list(input())
S = ''
for i in s:
if i == '0' or i == '1':
S += i
elif i == 'B' and len(S) != 0:
S = S[:-1]
print(S) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,223 |
s947937580 | p04030 | u474270503 | 1538774868 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 206 | s=input()
ans=[]
for i in range(len(s)):
if s[i]=='0':
ans.append('0')
if s[i]=='1':
ans.append('1')
if s[i]=='B' and len(ans)>0:
ans.pop(len(ans)-1)
print(''.join(ans))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,224 |
s673547477 | p04030 | u596276291 | 1538610468 | Python | Python (3.4.3) | py | Accepted | 32 | 4072 | 920 | from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursi... | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,225 |
s831810256 | p04030 | u426108351 | 1538591722 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 223 | s = input()
ans = []
for i in range(len(s)):
if s[i] == "0":
ans.append("0")
elif s[i] == "1":
ans.append("1")
elif s[i] == "B":
if ans != []:
ans.pop()
print("".join(ans))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,226 |
s753674417 | p04030 | u940102677 | 1538540053 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 127 | s = list(input())
a = []
for i in s:
if i == "0" or i == "1" :
a += [i]
elif a != []:
del a[-1]
print("".join(a)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,227 |
s103353476 | p04030 | u214617707 | 1538357790 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 157 | s = input()
t = ""
for i in range(len(s)):
if s[i] == "0":
t += "0"
elif s[i] == "1":
t += "1"
else:
t = t[:-1]
print(t) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,228 |
s174154129 | p04030 | u657913472 | 1537867876 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 135 | s=input();c=0;t='';
for i in range(len(s)-1,-1,-1):
if s[i]=='B':c+=1
else:
if c>0:c-=1
else:t=s[i]+t
print(t)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,229 |
s081605262 | p04030 | u589087860 | 1537833970 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 237 | s = input()
a = []
ans = ""
for i in range(len(s)):
if s[i] == '0':
a.append('0')
elif s[i] == '1':
a.append('1')
else:
if len(a) != 0:
a.pop()
#print(a)
ans = "".join(a)
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,230 |
s971413905 | p04030 | u099918199 | 1537817408 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 179 | s = str(input())
list = list(s)
count = 0
ans = ""
while count < len(list):
if list[count] == "B":
ans = ans[:-1]
else:
ans += list[count]
count += 1
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,231 |
s025737609 | p04030 | u853900545 | 1537719647 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 102 | s = input()
a = ''
for _ in s:
if _ == 'B':
a = a[:-1]
else:
a += _
print(a) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,232 |
s204834750 | p04030 | u879870653 | 1537574973 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 170 | S = list(input())
T = []
for i in range(len(S)) :
if S[i] != "B" :
T.append(S[i])
else :
if len(T) != 0 :
T.pop(-1)
print("".join(T))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,233 |
s082157395 | p04030 | u608088992 | 1537556016 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 149 | s = list(input())
output = ""
for i in range(len(s)):
if s[i] == "B":
output = output[:-1]
else:
output += s[i]
print(output) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,234 |
s191210324 | p04030 | u457901067 | 1537507312 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 129 | S = input()
ans = []
for ch in S:
if ch != "B":
ans.append(ch)
elif len(ans) > 0:
ans.pop()
print("".join(ans)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,235 |
s449949212 | p04030 | u140342018 | 1537473292 | Python | Python (3.4.3) | py | Accepted | 18 | 2940 | 108 | s = input()
ans = ''
for i in s:
if i=='B':
ans = ans[:-1]
else:
ans += i
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,236 |
s454611207 | p04030 | u177040005 | 1537405627 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 142 | S = input()
ans = ''
for s in S:
if s == 'B':
if len(ans) != 0:
ans = ans[:-1]
else:
ans += s
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,237 |
s430997841 | p04030 | u461636820 | 1537327053 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 125 | s = input()
result = ''
for i in s:
if i == 'B':
result = result[:-1]
else:
result += i
print(result) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,238 |
s007268286 | p04030 | u505420467 | 1537296349 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 228 | s=input()
a=[]
for i in range(len(s)):
if s[i]=='0':
a.append('0')
elif s[i]=='1':
a.append('1')
else:
if len(a)!=0:
trash=a.pop()
else:
pass
print(''.join(a))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,239 |
s383388205 | p04030 | u611249982 | 1537166354 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 169 | #!/usr/bin/python3
# -*- coding: utf-8 -*-
s = input()
t = []
for si in s:
if si != 'B':
t.append(si)
elif t != []:
t.pop()
print(''.join(t))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,240 |
s255380990 | p04030 | u932465688 | 1537138050 | Python | Python (3.4.3) | py | Accepted | 17 | 3064 | 192 | s = input()
L = []
for i in range(len(s)):
if (s[i] == '0'):
L.append('0')
elif (s[i] == '1'):
L.append('1')
else:
if (len(L) != 0):
del L[len(L)-1]
print((''.join(L))) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,241 |
s806381259 | p04030 | u102126195 | 1536602787 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 222 | s = list(input())
S = []
for i in s:
if i == "0":
S.append(0)
elif i == "1":
S.append(1)
elif i == "B":
if len(S) != 0:
del S[-1]
for i in S:
print(i, end = "")
print()
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,242 |
s319126731 | p04030 | u787562674 | 1536559800 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 129 | s = str(input())
while 'B' in s:
if s[0] == 'B':
s=s[1:]
s=s.replace('0B','')
s=s.replace('1B','')
print(s) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,243 |
s242013104 | p04030 | u017810624 | 1536370408 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 73 | a=input()
b=''
for x in a:
if x=='B':b=b[:-1]
else:b=b+x
print(b) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,244 |
s385333444 | p04030 | u466105944 | 1536245533 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 258 | def convert_input(input_str):
result = ''
for s in input_str:
if s == 'B':
result = result[:-1]
else:
result += s
return result
if __name__ == '__main__':
s = input()
print (convert_input(s)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,245 |
s098321259 | p04030 | u863841238 | 1536179738 | Python | Python (3.4.3) | py | Accepted | 19 | 3060 | 134 | s = input()
result = ''
for i in s:
if i == 'B':
result = result[:-1]
else:
result = result + i
print (result) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,246 |
s656820397 | p04030 | u461636820 | 1536022632 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 115 | S = input()
text = ''
for i in S:
if i == 'B':
text = text[:-1]
else:
text += i
print(text) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,247 |
s195246035 | p04030 | u461636820 | 1536017866 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 235 | s = input()
list = []
for i in s:
if i == '0':
list.append('0')
elif i == 'B':
if len(list) == 0:
continue
else:
list.pop()
else:
list.append('1')
print(''.join(list)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,248 |
s737819347 | p04030 | u698479721 | 1535734368 | Python | Python (3.4.3) | py | Accepted | 20 | 2940 | 164 | s = input()
text = ''
for letters in s:
if letters == 'B':
if text == '':
pass
else:
text = text[0:-1]
else:
text += letters
print(text) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,249 |
s470821378 | p04030 | u525423408 | 1535632728 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 233 | s=input()
a=[]
for i in range(len(s)):
if s[i]=="B":
if a==[]:
continue
else:
del a[-1]
elif s[i]=="0":
a.append("0")
elif s[i]=="1":
a.append("1")
print("".join(a)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,250 |
s014670519 | p04030 | u513081876 | 1535430183 | Python | Python (3.4.3) | py | Accepted | 19 | 3064 | 229 | s = (input())
ans = []
for i in s:
if i == '0':
ans.append(0)
elif i == '1':
ans.append(1)
elif i == 'B':
if len(ans) >= 1:
del ans[-1]
ans = list(map(str, ans))
print(''.join(ans)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,251 |
s087159626 | p04030 | u221345507 | 1534700496 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 255 | s=input()
data=[]
for i in range (len(s)):
if s[i]=='0':
data.append('0')
elif s[i]=='1':
data.append('1')
else:
if len(data)==0:
continue
else:
data.pop(len(data)-1)
print(''.join(data)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,252 |
s978502976 | p04030 | u756569003 | 1534457150 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 171 | s = input()
out = ''
for i in s:
if i == '0' or i == '1':
out += i
elif i == 'B':
if len(out) > 0:
out = out[:len(out)-1]
print(out)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,253 |
s875866750 | p04030 | u827202523 | 1534421237 | Python | Python (3.4.3) | py | Accepted | 18 | 2940 | 160 | STR = input()
ans = ""
for s in STR:
if s == "1" or s == "0":
ans += s
else:
if ans == "":
pass
else:
ans = ans[:-1]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,254 |
s770454393 | p04030 | u832039789 | 1534416991 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 90 | res = ''
for i in input():
if i=='B':
res = res[:-1]
else:
res += i
print(res) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,255 |
s808017827 | p04030 | u270681687 | 1534415431 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 165 | s = input()
ans = ""
for i in s:
if i == "0":
ans += "0"
elif i == "1":
ans += "1"
elif len(ans) > 0:
ans = ans[:-1]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,256 |
s010241738 | p04030 | u631277801 | 1534415349 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 279 | ans = ""
s = input()
for i in range(len(s)):
if s[i] == '0':
ans = ans + '0'
elif s[i] == '1':
ans = ans + '1'
elif s[i] == 'B':
if ans == "":
pass
else:
ans = ans[:-1]
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,257 |
s026116522 | p04030 | u692632484 | 1534415221 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 87 | s=input()
res=""
for c in s:
if c=='B':
res=res[:-1]
else:
res=res+c
print(res)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,258 |
s206877428 | p04030 | u761320129 | 1534415205 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 139 | s = input()
ans = []
for c in s:
if c == 'B':
if ans:
ans.pop()
else:
ans.append(c)
print(''.join(ans)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,259 |
s963963346 | p04030 | u451017206 | 1534298971 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 92 | ans = ''
for i in input():
if i == 'B':
ans = ans[:-1]
else:
ans += i
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,260 |
s120405726 | p04030 | u759651152 | 1534216274 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 368 | #-*-coding:utf-8-*-
def main():
s = list(input())
ans = []
for i in s:
if i == '0':
ans.append('0')
elif i == '1':
ans.append('1')
elif i == 'B':
if len(ans) == 0:
ans = []
else:
ans.pop()
print(''.j... | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,261 |
s630267669 | p04030 | u317785246 | 1534215091 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 108 | s = ""
for c in input():
if c == "0" or c == "1":
s += c
elif s:
s = s[:-1]
print(s) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,262 |
s145160741 | p04030 | u052347048 | 1534120501 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 166 | text = input()
lis = []
for i in range(len(text)):
if text[i] == "B" and len(lis) != 0:lis.pop()
elif text[i] != "B":lis.append(text[i])
print("".join(lis))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,263 |
s891132456 | p04030 | u761989513 | 1534033540 | Python | Python (3.4.3) | py | Accepted | 17 | 3060 | 145 | s = list(input())
a = []
for i in s:
if i == "0":
a.append("0")
elif i == "1":
a.append("1")
else:
a = a[:-1]
print("".join(a)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,264 |
s394259179 | p04030 | u277802731 | 1534016061 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 162 | #43b
s = list(input())
a =''
for i in s:
if i =='0' or i =='1':
a = a+i
else:
#最後の一つをスライス
a = a[:-1]
print(a) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,265 |
s505433916 | p04030 | u181668771 | 1533950915 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 175 | str = input()
output = ""
for n in str:
if(n=="0"):
output+="0"
elif(n=="1"):
output+="1"
elif(n=="B"):
output = output[:-1]
print(output)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,266 |
s223545576 | p04030 | u653642801 | 1533783109 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 248 |
def main():
s = list(input())
while "B" in s:
b = s.index("B")
if b != 0:
s.pop(b-1)
s.pop(b-1)
else:
s.pop(b)
print("".join(s))
if __name__ == "__main__":
main()
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,267 |
s257506586 | p04030 | u419686324 | 1533781298 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 92 | ans = ""
for s in input():
if s == "B":
ans = ans[:-1]
else:
ans += s
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,268 |
s814938551 | p04030 | u006657459 | 1533781231 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 145 | s = input()
r = ''
for i in range(len(s)):
if s[i] == 'B':
if len(r) > 0:
r = r[:-1]
else:
r += s[i]
print(r) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,269 |
s298876353 | p04030 | u006657459 | 1533781203 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 145 | s = input()
r = ''
for i in range(len(s)):
if s[i] == 'B':
if len(r) > 0:
r = r[:-1]
else:
r += s[i]
print(r) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,270 |
s737289987 | p04030 | u006657459 | 1533780796 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 145 | s = input()
r = ''
for i in range(len(s)):
if s[i] == 'B':
if len(r) > 0:
r = r[:-1]
else:
r += s[i]
print(r) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,271 |
s417213010 | p04030 | u006657459 | 1533780781 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 145 | s = input()
r = ''
for i in range(len(s)):
if s[i] == 'B':
if len(r) > 0:
r = r[:-1]
else:
r += s[i]
print(r) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,272 |
s654398415 | p04030 | u439396449 | 1533780710 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 141 | S = input()
ans = []
for s in S:
if s in ['0', '1']:
ans.append(s)
elif len(ans) > 0:
ans.pop()
print(''.join(ans))
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,273 |
s436384350 | p04030 | u769852547 | 1533780601 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 191 | import sys
s= list(input())
ans = []
for i in s:
if i == 'B':
if ans !=[]:
ans.pop(-1)
else:
ans.append(i)
print("".join(ans))
sys.exit(0)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,274 |
s156442432 | p04030 | u373274281 | 1533780561 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 141 | S = input()
ans = ''
for s in S:
if s == 'B':
if len(ans) > 0:
ans = ans[0:-1]
else:
ans += s
print(ans)
| p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,275 |
s991966440 | p04030 | u439396449 | 1533780352 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 140 | S = input()
ans = []
for s in S:
if s in ['0', '1']:
ans.append(s)
elif len(ans) > 0:
ans.pop()
print(''.join(ans)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,276 |
s617879064 | p04030 | u690536347 | 1533356327 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 129 | s=input()
l=[]
for i in s:
if i!="B":
l.append(i)
else:
try:
l.pop(-1)
except:
pass
print("".join(l)) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,277 |
s469962216 | p04030 | u278864208 | 1533347599 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 178 | s = input()
list = []
for i in s:
if i == 'B':
if list !=[]:
list.pop(-1)
else:
list.append(i)
for i in list:
print(i, end="") | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,278 |
s164612044 | p04030 | u780364430 | 1533186990 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 110 | s = input()
ans = ''
for i in s:
if i == 'B':
ans = ans[:-1]
else:
ans += i
print(ans) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,279 |
s938266378 | p04030 | u115682115 | 1533176850 | Python | Python (3.4.3) | py | Accepted | 17 | 2940 | 114 | s= list(input())
a = ''
for i in s:
if i=='0' or i=='1':
a=a+i
else:
a = a[0:-1]
print(a) | p04030 | <span class="lang-en">
<p>Score : <var>200</var> points</p>
<div class="part">
<section>
<h3>Problem Statement</h3><p>Sig has built his own keyboard. Designed for ultimate simplicity, this keyboard only has <var>3</var> keys on it: the <code>0</code> key, the <code>1</code> key and the backspace key.</p>
<p>To begin wi... | 01B0
| 00
| 1,206,280 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.