Fix: Ensure all skills are tracked as files, not submodules

This commit is contained in:
sck_0
2026-01-14 18:48:48 +01:00
parent 7f46ed8ca1
commit 8bd204708b
1113 changed files with 82065 additions and 2 deletions

View File

@@ -0,0 +1,29 @@
# HumanEval/161
# Loki Mode Multi-Agent Solution
# Attempts: 1
# Passed: True
def solve(s):
"""You are given a string s.
if s[i] is a letter, reverse its case from lower to upper or vise versa,
otherwise keep it as it is.
If the string contains no letters, reverse the string.
The function should return the resulted string.
Examples
solve("1234") = "4321"
solve("ab") = "AB"
solve("#a@C") = "#A@c"
"""
has_letter = any(c.isalpha() for c in s)
if not has_letter:
return s[::-1]
result = []
for c in s:
if c.isalpha():
result.append(c.swapcase())
else:
result.append(c)
return ''.join(result)