BFTAB - BF Vector

Your task is to put in the output nth character of the read input. You have to use BF.

Input

  • First line have x chars (1 <= x <= 99) and ends with a line feed (10)
  • Second line is one number n (00 <= n <= 99)

Output

It's only one character.

Example

Input:
01234567
02

Output:
2
Input:
0112ok3-12kewpl11,2eo12o3ke12ls12w1io2j34e12md
14

Output:
l

Added by:Marek Kotewicz
Date:2012-02-27
Time limit:1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:BF

hide comments
2018-08-26 02:09:30
AC in Brainf**k... 256 characters...
2014-12-10 17:22:23 Vamsi Krishna Avula
AC in one go :D, had a tough time debugging though!
@cyclops and @jander 65 bytes is incredible!
2013-01-13 22:10:27 Marek Kotewicz
@Asheesh
in 6th input file are 99 chars
2013-01-12 15:01:59 Jander
@Mitch - it might be an good one for golfing. I'm down to 66 so far.
2013-01-02 05:13:20 Aditya Pande
accepted in 1st attempt....
:)
@mitch my submission is 189 bytes with comments and 2 times 48-.
if i try i can get it down to ~80 bytes

Last edit: 2013-01-02 07:48:00
2012-12-22 14:31:29 Mitch Schwartz
I don't know if anyone else tried to golf this, but my best is 65 bytes for anyone interested.
2012-10-13 16:01:51 Asheesh Ranjan
What is in the 6th input file ?! It keeps giving me TLE
Uptill 5th input file, my code runs fine...

Last edit: 2012-10-13 17:26:19
2012-07-23 12:48:52 Saurabh Jain
nice question.!! enjoyed solving it and getting AC at one go. :)
2012-07-20 18:43:50 (Tjandra Satria Gunawan)(曾毅昆)
Yeah! got AC on first try ;)
2012-03-15 12:40:33 Marek Kotewicz
it wont be
© Spoj.com. All Rights Reserved. Spoj uses Sphere Engine™ © by Sphere Research Labs.