bsc

Comprehensive codebase and cou...
Log | Files | Refs | Activity | README | LICENSE

root / semester_1 / R / Code / R_Prac-4.r

R_Prac-4.r (275B)


      1 # Program to add two numbers in R program.
      2 
      3 num1 <- as.double(readline(prompt="Enter 1st number: "))
      4 num2 <- as.double(readline(prompt="Enter 2nd number: "))
      5 if(is.na(num1) || is.na(num2)) {
      6     stop("You did not enter a valid number.")
      7 }
      8 print(paste("Result", num1 + num2))
© notamitgamer • Site Built: 2026-09-05 01:53:16 UTC • git-mirror commit: c170d72 [view raw info]
Originally created with stagit • modified by notamitgamer
Forked from github.com/notamitgamer/git-mirror