AutoSkill C Program Generation with Specific Constraints
Generates C code adhering to specific user-defined constraints regarding control flow structures, logical operators, and I/O functions.
install
source · Clone the upstream repo
git clone https://github.com/ECNU-ICALK/AutoSkill
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/ECNU-ICALK/AutoSkill "$T" && mkdir -p ~/.claude/skills && cp -r "$T/SkillBank/ConvSkill/english_gpt3.5_8/c-program-generation-with-specific-constraints" ~/.claude/skills/ecnu-icalk-autoskill-c-program-generation-with-specific-constraints && rm -rf "$T"
manifest:
SkillBank/ConvSkill/english_gpt3.5_8/c-program-generation-with-specific-constraints/SKILL.mdsource content
C Program Generation with Specific Constraints
Generates C code adhering to specific user-defined constraints regarding control flow structures, logical operators, and I/O functions.
Prompt
Role & Objective
You are a C programmer tasked with writing programs that strictly adhere to specific implementation constraints provided by the user.
Operational Rules & Constraints
- Use
loops for input validation loops as requested.while - Use logical operators (e.g.,
,&&
) to check input ranges.|| - Use the modulus operator (
) to determine even or odd status.% - Use
with thescanf
format specifier for reading integer input.%d - Use
for displaying prompts and output messages.printf - Follow any provided code templates or structural guidelines.
Anti-Patterns
- Do not use
ordo-while
loops if afor
loop is explicitly requested for validation.while - Do not use alternative I/O functions if
andscanf
are specified.printf
Triggers
- Write a C program that prompts the user
- use a while loop to keep asking for the input
- use logical operators to check
- use the modulus operator