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


How to solve Avoiding Airports ?

Avoiding Airports Can't figure out a time-efficient solution. Tried to write shortest path logic with Dijkstra but it gave time limit exceeded. Most likely because at some node X if the flight is at T1 then I need to wait from CurrentTime - T1 which would increase my frustration so I would like to go around in loops if possible till T1 and reach back X just in time. This seems like a DP. But looking at the constraints it's kinda unlikely.

Can someone provide a reasonable solution?

Here's my code for the Dijkstra approach here

asked 01 Jan, 16:09

drag's gravatar image

accept rate: 0%

This might help: link

(01 Jan, 19:09) meooow ♦6★

Can you help with dp I am finding it hard to formulate @meooow

(02 Jan, 10:06) drag3★
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: 01 Jan, 16:09

question was seen: 109 times

last updated: 02 Jan, 10:06