nodejs-scanf
scanf for node.js 👽
Install
npm i nodejs-scanf
Example
-
scanf
read stdin async.
params:
format
,handler
format
:%s string %d integer %f float %c character
let scanf = ;// input: 'hello world';// input: 'hello 2017';// input: '2017-04-06' -
scanfSync
read stdin sync
params:
format
return a array
let scanfSync = ;let year month day = ;let welcome year = ;// input welcome,2017//welcome: 'welcome'// year: 2017 -
sscanf
read input string
params:
input
,format
,handler
License
MIT