SHARE
TWEET

Untitled

a guest Oct 18th, 2019 85 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. process.stdin.resume()
  2. process.stdin.setEncoding('utf8')
  3.  
  4.  
  5. console.log('How old are you ? ')
  6. process.stdin.on('data', (age) => {
  7.   let date = 2019 - age
  8.   if(age < 99 && age > 0){
  9.     console.log('you were born in ' + date)
  10.   } else{
  11.     console.log('ments pas')
  12.   }
  13.   process.exit()
  14. })
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top