The whole single point goes to tsh73. Thank you for pushing through and coming up with a solution!
Weekly Challenge problem #5: Triangle numbers [level: olympiad]
Triangle number is a number of dots, which can fill an equilateral triangle. For example, you can make a triangle out of three dots, so it's a triangle number. n-th triangle number is the number of dots in a triangle with side of n dots. Triangle number sequence is created like so: first triangle number is 1, second number is 2 bigger than first, third - 3 bigger than second and so on. Triangle number sequence is: 1, 3, 6, 10, 15... Write a program, that would determine if a number is a triangle number or not.
Data format: Positive number in [1, 4294967296] entered with a keyboard.
Output: The answer. Either "Yes" if number is a triangle number or "No" if number is not a triangle number.
Input/Output (keyboard, screen)
Should be easier than the last one. Let me know if I need to clarify the translations. I know I can sometimes be a bit off with that.
Post by tenochtitlanuk on Jun 2, 2020 11:10:51 GMT -5
In English we say things ( like difficulty of problems) 'differ like chalk and cheese'. After half an hour I still did not understand the data format of the inputs of Challenge 5. EDITSorry- meant number 4. Well done Anatoly- much kudos! I get it now, by reverse engineering your solution.
This problem 5 is much more direct. I hadn't noticed before that 666 ( the Number of the Beast') is triangular. For fun I thought I'd draw the triangles, but my output device doesn't have the required resolution. Looks pretty up to low thousands.. My printer can only get to 300dpi across 8 inches... Anyone got an adequate one, say I rather hopefully and tongue-in-cheek!!
Post by tenochtitlanuk on Jun 3, 2020 11:55:10 GMT -5
Linux user for years ( but have access to a couple of W10 machines) and main machine is Mint- but I play with other versions. Currently trying Linux Lite - most of my machines are old, low-spec technology. Search the forum for 'Linux' and user 'tenochtitlanuk' for lots of my posts mentioning Linux. But many more posts were on the old forum that was killed by it's host, along with so many others...