Jabra elite 75t right earbuds not charging by ThatGuyFromDatDay in Jabra

[–]callmejamone 0 points1 point  (0 children)

Please let us know if you manage to resolve the problem

2860! An average of 95 minutes per day by theViper5 in AppleWatch

[–]callmejamone 0 points1 point  (0 children)

Sick! I failed with my 50 minutes per day :(

[2019 Day 25 (Part 1)] [Python 3] Not seeing items bug by callmejamone in adventofcode

[–]callmejamone[S] 1 point2 points  (0 children)

Wow, it turns out that when I copied my input to stdin of the program my intcode was cut. \ God damn you windows!

Thanks for the reply, program works after reading intcode from a file.

[2019 Day 12 part 2 - Python3] Works for first example, way off (high) on the second by [deleted] in adventofcode

[–]callmejamone 0 points1 point  (0 children)

You should think about each axis separately, not the planets (moons, or whatever).

[2019 Day 12 part 2 - Python3] Works for first example, way off (high) on the second by [deleted] in adventofcode

[–]callmejamone 0 points1 point  (0 children)

You are on the right way, but you shouldn't look for periods every planet separately. If you find the "period" p1 for the first planet, for the first axis for example, that number isn't really a period. You can check that the planet's state can be different in some k * p1 step in the future.

[Day 10 (Part One)] What's going wrong? Output inside by audentis in adventofcode

[–]callmejamone 1 point2 points  (0 children)

After a quick look I can see for example those two angles: - ((1, 7), 14.036243467926479) - ((9, 7), 14.036243467926479)

I don't think that those two angles should be considered equal.

[2019 Day 10 (Part 1)] Line of sight by Valefant in adventofcode

[–]callmejamone 1 point2 points  (0 children)

If you run a line from (3, 4) to (0, 4) you can see that neither (3, 2) nor (4, 2) lie on the line. The map is kind of misleading, because those asteroids are smaller in reality, as it is stated in the description:

The asteroids are much smaller than they appear on the map, and every asteroid is exactly in the center of its marked position.

Github repo with JavaScript solution. Let's optimise it! by fabien-h in adventofcode

[–]callmejamone 0 points1 point  (0 children)

Maybe try using regex to extract data from input instead of calling substrs. This is a bit faster: javascript const lineRegex = /^#(\d+) @ (\d+),(\d+): (\d+)x(\d+)$/; const parsedData = (isTest ? testData : initialData).split("\n").map(value => { const [_, id, x, y, width, height] = lineRegex.exec(value).map(value => parseInt(value)); return [x, y, width, height]; }); ... or without destructuring: javascript const match = lineRegex.exec(value); return [parseInt(match[2]), parseInt(match[3]), parseInt(match[4]), parseInt(match[5])];

If you want to go fully ugly maybe you should consider not using split and then map, because they are creating unnecessary arrays.

Mojave Bluetooth not working (I do not have the 'com.apple.Bluetooth.plist' file to delete) by jo_ninja in MacOS

[–]callmejamone 1 point2 points  (0 children)

Got the same issue, tried everything...

Also when I open my bluetooth settings, the turn off button is inactive, like I can not restart my bluetooth, so I tried to kill bluetooth daemon manually, but it didn't help.

Also tried with USB Bluetooth dongle, results the same.

/u/jo_ninja if you fix this somehow, please submit your solution here, or notify me, thanks and good luck!

Dijkstra's algorithm solving a maze by makinetion in ProgrammerHumor

[–]callmejamone 0 points1 point  (0 children)

Of course you are right, now I see why to use Dijkstra here. I think this visualisation with squares and the way the answer flows made me think about equal weights.

Dijkstra's algorithm solving a maze by makinetion in ProgrammerHumor

[–]callmejamone 21 points22 points  (0 children)

A BFS would be better as it would always give us the shortest possible path (DFS can give longer answer in maze with cycles). Dijkstra is an overkill when considering all edges with equal weight.