You are not logged in. Please login at www.codechef.com to post your questions!

×

Fast I/O with strings

Hi everyone! I want to know that is there a way like getchar unlocked to input character arrays or strings way more faster? Besides gets, what else can I use to take string or character array as input from stdin faster?

asked 08 Nov '14, 20:10

xiaoyu_02's gravatar image

2★xiaoyu_02
5531923
accept rate: 5%


This is one of my solns where i have used string ip using getchar_unlocked...it did make it faster but cant say if it is faster than gets...hope this helps...:)

link

answered 08 Nov '14, 20:34

kunal361's gravatar image

4★kunal361
6.0k133272
accept rate: 21%

toggle preview
Preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:

×1,919
×643
×28
×19

question asked: 08 Nov '14, 20:10

question was seen: 4,295 times

last updated: 08 Nov '14, 20:34