simulateC: A function for simulation of generalized birthday problem

Description Usage Arguments Value Examples

View source: R/RcppExports.R View source: R/simulateC.R

Description

A function for simulation of generalized birthday problem

Usage

1
simulateC(k = 2, room = 23, replicate = 1e+05)

Arguments

k

Integer. k persons shared birthday.

room

Integer. Room size to be tested.

repliate

Integer. Replicate size.

Value

A floating value indicating the probability of at least k persons sharing birthday in a room

Examples

1
2
3
4
system.time({
p <- simulateC(k=2, roomSize=23, replicate=1e7)
})
p

Chang-Yu-Chang/GeneralBirthdayProblem documentation built on May 23, 2019, 2:42 p.m.