Signed-off-by: Hadi <112569860+anotherhadi@users.noreply.github.com>
This commit is contained in:
Hadi
2026-05-12 19:12:29 +02:00
commit e8e64eff12
101 changed files with 10081 additions and 0 deletions
+72
View File
@@ -0,0 +1,72 @@
package teapot
import "strings"
// FrameLines returns the number of visual lines in a teapot frame.
func FrameLines() int {
frames := TeapotFrames()
if len(frames) == 0 {
return 0
}
return strings.Count(frames[0], "\n") + 1
}
func Teapot() string {
return "" +
" ) \n" +
" ( \n" +
" ) \n" +
" .-.,--^--. _ \n" +
" \\\\| `---' |//\n" +
" \\| / \n" +
" _\\_______/_ "
}
func TeapotFrames() []string {
return []string{
"" +
" ) \n" +
" ( \n" +
" ) \n" +
" .-.,--^--. _ \n" +
" \\\\| `---' |//\n" +
" \\| / \n" +
" _\\_______/_ ",
"" +
" ) \n" +
" ( \n" +
" ) \n" +
" .-.,--^--. _ \n" +
" \\\\| `---' |//\n" +
" \\| / \n" +
" _\\_______/_ ",
"" +
" ) \n" +
" ( \n" +
" ) \n" +
" .-.,--^--. _ \n" +
" \\\\| `---' |//\n" +
" \\| / \n" +
" _\\_______/_ ",
"" +
" \n" +
" ( \n" +
" ) \n" +
" .-.,--^--. _ \n" +
" \\\\| `---' |//\n" +
" \\| / \n" +
" _\\_______/_ ",
"" +
" \n" +
" (( \n" +
" ) \n" +
" .-.,--^--. _ \n" +
" \\\\| `---' |//\n" +
" \\| / \n" +
" _\\_______/_ ",
}
}