Recent postings
-
Project Euler
[C++/Python] Project Euler #55 - Lychrel Numbers
This problem is also a difficulty level 5% problem.A Lychrel number is a positive integer that, when expressed in base 10 and added to its reverse, does not form a palindrome. If the result is not a palindrome, the process is repeated by reversing the number and adding again.Theoretically, since the numbers increase gradually, it is assumed that eventually a palindrome (a number that reads the s..
-
Project Euler
[C/C++] Project Euler #54 - Poker Hands
I didn’t find this problem particularly difficult, but it certainly is quite tedious.On the Project Euler site, it is rated as a 10% difficulty problem.I’ve never made a poker-style game before, but determining who wins according to poker rules is the most important part of a poker game. Everything else is just the interface.This problem is quite long.Ultimately, the main point is to determine h..
-
BOJ
[C/C++] BOJ #1041 - Dice
This problem can be easily solved if you can visualize the geometric structure of a cube. Perhaps that’s why its difficulty level is quite low. The difficulty is Silver III. While it is harder than Bronze-level problems, it’s not too difficult.As of now, the correct answer rate is 22.6%, which is quite low, and there are 531 correct submissions.The goal of the problem is to calculate the minimum..
-
Project Euler
[C/C++] Project Euler #53 - Combinatoric Selections
This problem is a simple one. As long as you know the combination formula, it’s easy to solve.When n varies from 1 to 100, you need to calculate the number of times the combination value \(_nC_r\) exceeds one million.Even with a brute-force approach, you only need to compute combinations 10,100 times.If you know that \(_nC_r = nC{n-r}\), you can reduce the calculations by half. Because of its sy..
-
Project Euler
[C/C++] Project Euler #52 - Permuted Multiples
Problem 52 is so famous that I was able to find the answer without even writing a program after just reading the problem.This problem is related to recurring decimals and prime numbers.The problem itself is not difficult, so you can solve it one way or another. It’s a 5% difficulty problem. (Problem 51 had briefly jumped to 15% difficulty.)A number like 125874, when multiplied by 2, becomes 2517..