solving one question of probability using R- STUDIO

I want to see your code and you output from R. You can choose to make this an
Rmarkdown file or Jupiter notebook or… It should be a similar file format to what you
turned in for Lab 1 and 2
THE QUESTION.
In the casino game of Egyptian Battle, every player is dealt a card from an ordinary deck, including the
dealer, and the player with the highest card value wins. In the case of a tie, the dealer wins
automatically. The cards are replaced and reshuffled each round. (Ace is the highest.)
a. Simulate 15 games of one player against the dealer and determine the number of times the player
wins. Repeat this process 50 more times and plot your findings on a histogram with a density
curve.
b. Simulate 150 games and graphically display the cumulative proportion of winning.

c. Simulate 15, 150, 1500, 15000 games of you against the dealer. Create a table for the number of
wins for each, the probability of winning a given game, etc.

d. What does part (b) show about the law of large numbers?
e. Find the theoretical probability of winning a single hand of the game
The last pages include an explanation for R studio
I send you lab 1 and lab 2 which they were solved to take idea