1
edit
Changes
→Progress
==== '''Source File(s)''' ====
Link: https://drive.google.com/file/d/0B8GUuIUqdEJES3VEOGRnYmRNaEk
==== '''Code Snippet''' ====
// loops through user amount of rounds of sets of points
for(i = 0; i < points; i++)
{
x = randNum();
y = randNum();
// check if point resides within the circle
if (((x*x) + (y*y)) <= 1.0)
{
score++;
}
}
// calculate pi
pi = 4.0 * (float)score/(float)points;
==== '''Compilation and Running''' ====
==== '''Serial Results''' ====
[[File:Pi_serial_results.jpg|border]]
=== '''Assignment 2''' ===