Created
June 4, 2018 10:44
-
-
Save sivakumarbdu/591f6faa9fe55f2d1c4744703b77c193 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interest= ["nature", "agriculture", "farming", "ai", "infography", "memes", "DIY home", "electronics", "web design", "garden design"] | |
survey_data = {} | |
10000.times do | n | | |
primary_interest = interest[Random.rand(interest.size)] | |
secondary_interest = interest[Random.rand(interest.size)] | |
survey_data[n.to_s] = {:name => Faker::Name.name, email: Faker::Internet.email, | |
interest: [primary_interest, secondary_interest], age: Random.rand(18..65)} | |
end | |
p survey_data | |
#survey_data will have mocke data |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment