Question: R Coding Question Please help by answering all the questions and their subparts. Thanks! 1. Write R code that asks you to input a positive

R Coding Question

Please help by answering all the questions and their subparts. Thanks!

R Coding QuestionPlease help by answering all the questions and their subparts.

1. Write R code that asks you to input a positive integer n and then computes n! and writes it back out to the screen. You may not use the built-in function factorial(). Use good programming style. Run it a couple times and include the console runs in your hand-in. Use an R script file and hand in the R script. 2. Using a for-loop, write R code that computes the first 2000 terms of summing 1', that is, computes z where n=2000 Z = E n=1 What is this number z? 3. Using a while-loop that runs for 25 iterations, print to screen for each iteration of the loop what its iteration number is. Identify each exercise and sub exercise and include the answers (R outputs) to the file. Together with your R script of your code, also hand in a text file (ends in .txt) of the cleaned-up console run too

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!