r/codinginterview • • Jul 27 '20

C# has no Priority Queue

So C# does not implement a min/max heap (PQ)... this is obviously not helpful for coding interviews. I want to do my coding interviews in C# and I’d prefer not to implement a PQ from scratch during an interview. How do you csharpers handle this?

3 Upvotes

2 comments sorted by

1

u/wodahs1 Jul 27 '20

I’d just say I’m using a priority queue library. Should be ok. They won’t expect you to make a priority queue.

On another note, why not just use java? They syntax is similar anyway.

1

u/DisDatDragon Jul 27 '20

Its an issue if you need to have working code. But yeah, java has a built in implementation for Priority Queue and the languages are very similar.