If you really want to learn C++ and improve through the challenges, don't just copy my solutions. You won't learn anything that way! (Cheating and plagiarizing is not permitted on the Codewars website. Violators will face account suspension or ban.)
My solutions to some Codewars challenges, programmed in C++, might not be the most sophisticated, but at least mostly easy to read and understand. However, a few are implemented rather poorly, as I am still a beginner.
Current C++ rank (since March 5, 2026): 4 kyu.
See also:
- My solutions to Codewars challenges - programmed in C
- My solutions to Codewars challenges - programmed in Pascal
- My solutions to Codewars challenges - programmed in Python
The code I released here into the public domain may appear in third-party projects. I do not maintain, endorse, or have any affiliation with such projects. Any malicious or deceptive use is unauthorized and should be reported to the hosting platform.
- <2 kyu> Evaluate mathematical expression - Solution: eval_math_expression.cpp
- <3 kyu> The Lift - Solution: the_lift.cpp
- <4 kyu> Grazing Donkey - Solution: grazing_donkey.cpp
- <4 kyu> Matrix Determinant - Solution: determinant.cpp
- <4 kyu> Number of Proper Fractions with Denominator d - Solution: number_proper_fractions.cpp
- <4 kyu> Vigenère Cipher Helper - Solution: vigenere_cipher_helper.cpp
- <5 kyu> Beeramid - Solution: beeramid.cpp
- <5 kyu> Build a quadratic equation - Solution: build_quadratic_equation.cpp
- <5 kyu> Calculating with Functions - Solution: calculating_with_functions.cpp
- <5 kyu> Lazy Repeater - Solution: lazy_repeater.cpp
- <5 kyu> Rot13 - Solution: rot13.cpp
- <5 kyu> Simultaneous Equations - Three Variables - Solution: three_equations_three_unknowns.cpp
- <5 kyu> The Hashtag Generator - Solution: hashtag_generator.cpp
- <6 kyu> Are they the "same"? - Solution: same_arrays.cpp
- <6 kyu> Banker's Plan - Solution: bankers_plan.cpp
- <6 kyu> Bouncing Balls - Solution: bouncing_balls.cpp
- <6 kyu> Calculate the area of a regular n sides polygon inside a circle of radius r - Solution: polygon_area_inside_circle.cpp
- <6 kyu> Combinations Produced by n Coin Flips - Solution: coin_flips.cpp
- <6 kyu> Common array elements - Solution: common_array_elements.cpp
- <6 kyu> Count the smiley faces! - Solution: count_smileys.cpp
- <6 kyu> Delete occurrences of an element if it occurs more than n times - Solution: delete_occurrences_above_limit.cpp
- <6 kyu> Duplicate Encoder - Solution: duplicate_encoder.cpp
- <6 kyu> Find most frequent element in a list - Solution: find_most_frequent.cpp
- <6 kyu> Find the missing letter - Solution: find_missing_letter.cpp
- <6 kyu> Find the odd int - Solution: find_the_odd_int.cpp
- <6 kyu> FIXME: Hello - Solution: fixme_hello.cpp
- <6 kyu> Highest Scoring Word - Solution: highest_scoring_word.cpp
- <6 kyu> (L33T + Grεεκ) Case - Solution: leet_greek_case.cpp
- <6 kyu> Make the Deadfish Swim - Solution: make_the_deadfish_swim.cpp
- <6 kyu> Mexican Wave - Solution: mexican_wave.cpp
- <6 kyu> Multiple of 11 - Solution: multiple_of_eleven.cpp
- <6 kyu> Potion Class 101 - Solution: potion_class_101.cpp
- <6 kyu> Prime Factors - Solution: prime_factors.cpp
- <6 kyu> Prime Word - Solution: prime_word.cpp
- <6 kyu> Rectangle into Squares - Solution: rectangle_into_squares.cpp
- <6 kyu> Split Strings - Solution: split_strings.cpp
- <6 kyu> Sums of Parts - Solution: sum_of_parts.cpp
- <6 kyu> Sum The Tree - Solution: sum_the_tree.cpp
- <6 kyu> Train your skills in creation of classes - Solution: class_creation_skills.cpp
- <6 kyu> Unique In Order - Solution: unique_in_order.cpp
- <7 kyu> Convert Time to String - Solution: convert_time_to_string.cpp
- <7 kyu> Correct the time-string - Solution: correct_time_string.cpp
- <7 kyu> Descending Order - Solution: descending_order.cpp
- <7 kyu> Disemvowel Trolls - Solution: disemvowel.cpp
- <7 kyu> Drone Fly-By - Solution: drone_fly_by.cpp
- <7 kyu> Find Count of Most Frequent Item in an Array - Solution: most_frequent_item_count.cpp
- <7 kyu> Friend or Foe? - Solution: friend_or_foe.cpp
- <7 kyu> FromPascalToCpp - Solution: from_pascal_to_cpp.cpp
- <7 kyu> Fun with operators - Solution: fun_with_operators.cpp
- <7 kyu> Growth of a Population - Solution: population_growth.cpp
- <7 kyu> Isograms - Solution: isograms.cpp
- <7 kyu> Mumbling - Solution: mumbling.cpp
- <7 kyu> Number of People in the Bus - Solution: people_in_the_bus.cpp
- <7 kyu> Pointer Swap - Solution: pointer_swap.cpp
- <7 kyu> Printer Errors - Solution: printer_errors.cpp
- <7 kyu> Pyramid Structure Analyzer - Solution: pyramid_structure_analyzer.cpp
- <7 kyu> Remove All The Marked Elements of a List - Solution: remove_array_values.cpp
- <7 kyu> Shortest Word - Solution: shortest_word.cpp
- <7 kyu> Sort array by string length - Solution: sort_array_by_string_length.cpp
- <7 kyu> String matchup - Solution: string_matchup.cpp
- <7 kyu> String Scramble - Solution: string_scramble.cpp
- <7 kyu> Sum of odd numbers - Solution: sum_of_odd_numbers.cpp
- <7 kyu> The Office I - Outed - Solution: the_office_outed.cpp
- <7 kyu> You're a square! - Solution: is_square.cpp
- <8 kyu> Bin to Decimal - Solution: bin_to_decimal.cpp
- <8 kyu> Century From Year - Solution: century_from_year.cpp
- <8 kyu> Convert a Number to a String! - Solution: number_to_string.cpp
- <8 kyu> Convert boolean values to strings 'Yes' or 'No'. - Solution: boolean_to_string.cpp
- <8 kyu> Convert number to reversed array of digits - Solution: digitize.cpp
- <8 kyu> Count by X - Solution: count_by_x.cpp
- <8 kyu> Double Char - Solution: double_char.cpp
- <8 kyu> Find Maximum and Minimum Values of a List - Solution: find_maximum_and_minimum.cpp
- <8 kyu> Find the smallest integer in the array - Solution: smallest_value.cpp
- <8 kyu> Get the mean of an array - Solution: get_array_average.cpp
- <8 kyu> How good are you really? - Solution: how_good_really.cpp
- <8 kyu> I love you, a little , a lot, passionately ... not at all - Solution: how_much_i_love_you.cpp
- <8 kyu> Personalized Message - Solution: personalized_message.cpp
- <8 kyu> Remove First and Last Character - Solution: string_remove_first_last_char.cpp
- <8 kyu> Reversed Strings - Solution: string_reverse.cpp
- <8 kyu> String repeat - Solution: string_repeat.cpp
- <8 kyu> Sum Arrays - Solution: sum_arrays.cpp
- <8 kyu> Sum of positive - Solution: positive_sum.cpp
- <8 kyu> Third Angle of a Triangle - Solution: third_angle_triangle.cpp
