4
votes
A* algorithm implementation in modern C++
As I understand your code, a new node is pushed for every unvisited neighbour of the node that is visited.
A result of that is that the queue will contain, in many cases, duplicate nodes, or "...
4
votes
A* algorithm implementation in modern C++
Missing and redundant const
Make sure that all pointer and reference parameters that point to data that should not be modified are passed as ...
4
votes
C++ Eigen/Mex function to perform two pagewise convolutions on a 3D matrix with a simple kernel
This is a great question in most respects, but since the code sample doesn’t compile and can’t be tested, I can only give you a vague and speculative answer.
I’ll skip over your Item 1, because I have ...
2
votes
Merge a list of deeply nested HashMaps
any other approach ... that could help me squeeze a bit more performance ?
Choose a nice output format for your maps,
and serialize each one to a text file (or to an RDBMS).
For example the original <...
2
votes
Find all permutations of string using recursion
It's fine to reinvent the wheel. Overheated comments to the contrary, it's
perfectly fine to use classic algorithms as a vehicle to practice your coding
skills. Just be aware, if you didn't know ...
1
vote
Merge a list of deeply nested HashMaps
You present uncommented code.
While I might succeed figuring out what mergeMaps() achieves, it may be intended to do something slightly different:
Document you ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
algorithm × 5036java × 1271
python × 1189
performance × 991
c++ × 829
programming-challenge × 654
javascript × 489
c# × 405
strings × 352
python-3.x × 320
c × 318
sorting × 317
beginner × 308
graph × 260
array × 246
time-limit-exceeded × 242
tree × 216
recursion × 175
interview-questions × 168
python-2.x × 163
combinatorics × 132
complexity × 132
c++11 × 102
mathematics × 101
matrix × 97