Recent postings
-
BOJ
[C/C++] BOJ #1081 - Digit Sum
When a number is given, you can find the sum of all its digits. For example, for 47, the sum is \(4+7=11\). This problem asks you to find the sum of the digits of all numbers within a given range. This problem is similar to problem #1019. The only difference is that while #1019 asks for the sum of digits from 1 up to a given number, this problem provides a starting number for the range. Also, #..
-
Project Euler
[C/C++] Project Euler #67 - Maximum Path Sum II
Problem Overview“This is a problem with a difficulty of only about 5%, so it’s not very hard.However, it’s a problem that can be solved using basic algorithms such as the A algorithm, and it’s also applicable in many game programming scenarios.”*This suggests that while the problem is simple, it still provides a good opportunity to apply important foundational algorithms. Problems like this are ..
-
Project Euler
[C++/Python] Project Euler #66 - Diophantine equation
This problem has a difficulty level of 25%, but without mathematical background, it’s extremely hard to solve.If you try to just follow the formulas mechanically, this problem is very tough to crack.In this type of indeterminate equation where the solution is not fixed, finding integer solutions is something that, apart from brute-force substitution, would be unknown to someone who has only stud..
-
BOJ
[C/C++] BOJ #1074 - Z
This problem involves the concept of self-replication.The large shape forms a Z pattern, and the smaller shapes within also form Z patterns. The task is to find the number at a given row and column when the array is filled according to this Z-pattern structure.If the array is 2x2, the numbers are arranged in a Z pattern as shown in the diagram. As the size increases, the pattern becomes more com..
-
Project Euler
[Python] Project Euler #65 - Convergents of e
Project Euler Problem #65 is related to continued fractions. Specifically, the problem is as follows:The continued fraction expansion for the natural number e (Euler’s number) can be expressed in the following form:\[ e = [2; 1, 2, 1, 1, 4, 1, 1, 6, 1, 1, 8, 1, \dots] \]Here, the numbers inside the brackets represent the terms of the continued fraction expansion. The n-th convergent of the conti..