Skip to content

casprwang/print-shape

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

print-shape

print out a variety of shapes from your console

Usage

// index.js
const { triangle, square, rhombus } = require('print-shape')

triangle(6)
square(6)
rhombus(6)

execute with

# node index.js

in terminal

     /\
    /  \
   /    \
  /      \
 /        \
/----------\
|------|
|      |
|      |
|      |
|      |
|------|
  /-\
 /   \
/     \
\     /
 \   /
  \-/

API

.triangle(num: number): null

no return just log the shape in terminal

.square(num: number(>1)): null

no return just log the shape in terminal

.rhombus(num: number(even)): null

no return just log the shape in terminal

License

MIT © Song Wang

About

print out a variety of shapes from your console

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published