R_Prac-2.r (309B)
1 # Author: Amit Dutta (amitdutta4255@gmail.com) | Date: 25 Mar 2026 2 # Repo: https://github.com/notamitgamer/bsc 3 # License: MIT 4 5 # Check whether a number is even or odd. 6 7 num <- readline(prompt="Enter the number: ") 8 num <- as.integer(num) 9 print(paste(num, "is", ifelse(num %% 2 == 0, "EVEN", "ODD"), "number."))