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

×

queue problem

queue <node> q; what is this? how we use it ?where we use it? is there any header file to acces it?

asked 11 Mar '15, 00:37

rahulsup's gravatar image

1★rahulsup
251212
accept rate: 0%


I think you must be knowing that queue is abstract data type.See here. And to use queue in your program, you would have to write its whole code (push, pop and other functions). Now, to avoid all that overhead, there are libraries in C++ and Java which allow you to use queue and its functions directly in your program.

In C++, you would have to include queue header file. For more details and how to use its functions , see here. In Java, queue is defined in the collections. For more details and how to use its functions, see here and here.

link

answered 11 Mar '15, 01:30

shivam217's gravatar image

4★shivam217
8383515
accept rate: 20%

edited 11 Mar '15, 01:33

thanks shivam217

(11 Mar '15, 10:15) rahulsup1★

Hi Rahul, if you got the answer, then please accept the answer so that question can be closed. Thanks.

(11 Mar '15, 10:56) shivam2174★
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,404
×57
×22

question asked: 11 Mar '15, 00:37

question was seen: 1,029 times

last updated: 11 Mar '15, 10:56