+ 1

Can’t able to solve please help!!

You are planning a vacation in August. You are given a program that takes the month as input. Task Complete the code to output "vacation", if the given month is August. Don't output anything otherwise. Sample Input August Sample Output vacation var month = parseInt(readLine(), 10) //your code goes here How to proceed??

8th Sep 2021, 9:04 PM
Nizwm Borgoyari
Nizwm Borgoyari - avatar
5 Antworten
+ 3
Nizwm Borgoyari , before we can help you, you should show us your attempt first. if you have not done a try by yourself upto now, please do so. Put your code in playground and link it here. thanks!
8th Sep 2021, 11:26 PM
Lothar
Lothar - avatar
+ 3
Nizwm Borgoyari , you should use : var month = readLine() // parseInt(...) is for integers only and also: if (month == 'August') ... // you used assignment operator, comparison is '==' happy coding!
8th Sep 2021, 11:40 PM
Lothar
Lothar - avatar
+ 1
I tried here is the code var month = parseInt(readLine(),10) //your code goes here If (month = “August”) { console.log(“vacation”)}
8th Sep 2021, 11:31 PM
Nizwm Borgoyari
Nizwm Borgoyari - avatar
+ 1
Got it thank you so much
8th Sep 2021, 11:42 PM
Nizwm Borgoyari
Nizwm Borgoyari - avatar
0
You have completed Javascript right. Can you please help me out.
8th Sep 2021, 11:32 PM
Nizwm Borgoyari
Nizwm Borgoyari - avatar