Install
openclaw skills install algorithm-practiceđ¯ Interactive algorithm practice with 100+ problems across Easy/Medium/Hard difficulties. Generates ready-to-run code templates in Java & Python with built-in test cases. Perfect for coding interview preparation and algorithm learning. Covers arrays, strings, linked lists, trees, dynamic programming, graphs, and more.
openclaw skills install algorithm-practiceTransform your coding interview preparation with curated algorithm problems, auto-generated code templates, and instant test feedback.
User: åēįŽæŗéĸ / åˇéĸ / įģįŽæŗ / algo practice / æĨä¸ééĸ
The skill will:
User: åˇéĸ
AI: [Asks for difficulty preference]
User: Medium
AI: [Generates problem with templates]
Read algo_history.md from the workspace root to track previously assigned problems and ensure no duplicates.
# Algorithm Practice History
| # | Problem Name | Difficulty | Category | Date |
|---|-------------|------------|----------|------|
| 1 | TwoSum | Easy | Array, Hash Table | 2026-03-27 |
Use the AskUserQuestion tool:
Question: "Which difficulty level would you like?"
Options:
Create an original algorithm problem with:
LongestSubstring, MergeIntervals)Arrays, Strings, Linked Lists, Trees, Graphs, Dynamic Programming, Greedy, Backtracking, Sorting, Searching, Stack/Queue, Hash Tables, Two Pointers, Sliding Window, Bit Manipulation, BFS/DFS, Divide & Conquer
java/<ProblemName>.javaimport java.util.*;
public class <ProblemName> {
/**
* TODO: Implement your algorithm here
*
* <Brief description of function>
*
* @param <parameter description>
* @return <return value description>
*/
public <ReturnType> <methodName>(<Parameters>) {
// Write your code here
return <default value>;
}
public static void main(String[] args) {
<ProblemName> solution = new <ProblemName>();
int passed = 0;
int total = 0;
// Test Case 1: Normal case
total++;
<Type> result1 = solution.<methodName>(<input1>);
if (<check if result1 equals expected1>) {
System.out.println("Test Case " + total + ": â
Pass");
passed++;
} else {
System.out.println("Test Case " + total + ": â Fail");
System.out.println(" Input: <input description>");
System.out.println(" Expected: <expected output>");
System.out.println(" Actual: " + result1);
}
// Test Case 2-N: Include edge cases (minimum 5 total)
// Must cover: normal cases, boundary cases, special cases
System.out.println("\nResults: " + passed + "/" + total + " Passed");
if (passed == total) {
System.out.println("đ All tests passed!");
} else {
System.out.println("đĒ Keep trying! Review the failed cases above.");
}
}
}
python/<problem_name>.pyfrom typing import List, Optional
class Solution:
def <method_name>(self, <parameters>) -> <return_type>:
"""
TODO: Implement your algorithm here
<Brief description of function>
Args:
<parameter description>
Returns:
<return value description>
"""
# Write your code here
pass
def main():
solution = Solution()
passed = 0
total = 0
# Test Case 1: Normal case
total += 1
result1 = solution.<method_name>(<input1>)
if result1 == <expected1>:
print(f"Test Case {total}: â
Pass")
passed += 1
else:
print(f"Test Case {total}: â Fail")
print(f" Input: <input description>")
print(f" Expected: <expected output>")
print(f" Actual: {result1}")
# Test Case 2-N: Include edge cases (minimum 5 total)
# Must cover: normal cases, boundary cases, special cases
print(f"\nResults: {passed}/{total} Passed")
if passed == total:
print("đ All tests passed!")
else:
print("đĒ Keep trying! Review the failed cases above.")
if __name__ == "__main__":
main()
Arrays.equals() for Java arrays, == for Python listsAppend the problem to algo_history.md in workspace root:
# Algorithm Practice History
| # | Problem Name | Difficulty | Category | Date |
|---|-------------|------------|----------|------|
| 1 | TwoSum | Easy | Array, Hash Table | 2026-03-27 |
| 2 | MergeIntervals | Medium | Array, Sorting | 2026-03-27 |
Auto-increment the sequence number and use current date.
Display the complete problem with:
java/<ProblemName>.javapython/<problem_name>.pyalgo_history.md for your journey# Java
cd java
javac <ProblemName>.java && java <ProblemName>
# Python
python python/<problem_name>.py
ValidParentheses)java/ and python/ directories if they don't existAfter using this skill, users should:
đĄ Tip: This skill is perfect for daily algorithm practice. Try solving 1-2 problems per day to build strong problem-solving skills!