Solutions are presented as using the least memory and the fastest execution time. It also takes the top
10 most recent solutions from each language. If you want to limit to a specific index, click the
"Solved" button and go to that problem.
ContestId |
Name |
Phase |
Frozen |
Duration (Seconds) |
Relative Time |
Start Time |
188
|
Surprise Language Round 6 |
FINISHED |
False |
7200 |
393863399 |
May 25, 2012, 3:30 p.m. |
Problems
B"In this problem we'll use a stack which supports two types of operations: You are given a string which describes the sequence of operations to be performed on the stack. i-th character corresponds to i-th operation: Initially the stack is empty. Output the topmost number on the stack after executing all given operations. The only line of input contains a string of operations, consisting of characters xc2 xab+ xc2 xbb, xc2 xab* xc2 xbb and digits (0..9). The length of the string will be between 1 and 20 characters, inclusive. The given sequence of operations is guaranteed to be correct, i.e. the stack will have at least two elements before every math operation. The numbers on the stack will never exceed 106. Output a single number -- the topmost element of the stack after performing all given operations. In the first case the stack will end up containing a single number -- the result of calculating (1+2)*3+6*6. In the second case there are no math operations, so the answer will be the last number pushed on the stack."... |
Tutorials
Submissions
Submission Id |
Author(s) |
Index |
Submitted |
Verdict |
Language |
Test Set |
Tests Passed |
Time taken (ms) |
Memory Consumed (bytes) |
Tags |
Rating |
4058539 |
Router |
H |
July 13, 2013, 8:01 a.m. |
OK |
Roco |
TESTS |
44 |
15 |
0 |
|
1900 |
3669335 |
Omelianenko |
H |
May 4, 2013, 1:37 p.m. |
OK |
Roco |
TESTS |
44 |
15 |
0 |
|
1900 |
3037358 |
romanychda |
H |
Jan. 30, 2013, 2:54 p.m. |
OK |
Roco |
TESTS |
44 |
15 |
0 |
|
1900 |
3816692 |
yermak0v |
H |
June 2, 2013, 6:24 p.m. |
OK |
Roco |
TESTS |
44 |
15 |
102400 |
|
1900 |
60062179 |
Anar |
H |
Sept. 5, 2019, 7:29 a.m. |
OK |
Roco |
TESTS |
44 |
30 |
0 |
|
1900 |
5614495 |
PSDEV |
H |
Jan. 4, 2014, 7:58 a.m. |
OK |
Roco |
TESTS |
44 |
30 |
0 |
|
1900 |
68344343 |
nealzane |
H |
Jan. 7, 2020, 6:17 a.m. |
OK |
Roco |
TESTS |
44 |
30 |
102400 |
|
1900 |
61585027 |
sakif_khan |
H |
Oct. 1, 2019, 4:27 a.m. |
OK |
Roco |
TESTS |
44 |
30 |
102400 |
|
1900 |
46265466 |
nongi |
H |
Nov. 27, 2018, 2:02 a.m. |
OK |
Roco |
TESTS |
44 |
30 |
102400 |
|
1900 |
45751374 |
yongwhan |
H |
Nov. 15, 2018, 1:29 a.m. |
OK |
Roco |
TESTS |
44 |
30 |
102400 |
|
1900 |
remove filters
Back to search problems