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


SNSOCIAL- Can someone tell me what is wrong in this code?

please someone tell me why this code is not printing anything? link to my code

asked 03 Jun '17, 00:52

harry1995's gravatar image

accept rate: 5%

you should pop the element from the queue everytime


answered 03 Jun '17, 00:58

hruday968's gravatar image

accept rate: 14%

I think i did in this line Point point= que.removeFirst();

(03 Jun '17, 01:07) harry19954★

ok i got your point that should be inside the loop, thank you

(03 Jun '17, 01:14) harry19954★

yeah that should be inside the loop

(03 Jun '17, 01:28) hruday9684★

Well, to be honest I do not like that line "if((x+row[k])>=0 && (x+row[k])<n &&="" (y+col[k])="">=0 &&(y+col[k])<m && (visited[x+row[k]][y+col[k]])==0)" I think that esaytyper is somewhere here. Usually in such long lines we do a lot of typos, so check everything once again please.


answered 06 Jun '17, 15:27

hughe13's gravatar image

accept rate: 0%

toggle preview

Follow this question

By Email:

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



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "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:


question asked: 03 Jun '17, 00:52

question was seen: 907 times

last updated: 06 Jun '17, 15:27