Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
@SortOfTested And nobody wants future co-workers who simply aren't able to code. Let such students fail hard.
-
kiki353264yPlace a billions of random points inside a smallest possible square where your circle is fitted. Now for every point you have a flag like does it happen to be inside a circle or outside. You can easily calculate the area from there, good luck lol
-
https://mathsisfun.com/sine-cosine-...
IDK if this is the right approach, but that's how I would do it lol. -
C0D4681384yI'm with @Fast-nop on this one.
@Farah, do you know how to calculate the area of a circle from a mathematical standpoint? -
raspark17294yFolks, I think @farah is tryna say that calculating area of a circle in C++ is the best team win they had. It's tagged with weekly question. No need to get offensive lol.
-
Bruh.. fuck fuck fuck fuck fuck I though the rant said "How draw cicle by C". How the fuck, it's not even similar. 🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️🤦♂️
omg, that's it. I need some sleep. -
raspark17294y@Farah sorry, but you've misunderstood the platform. This is not for asking questions that could easily be solved with a quick Google search.
-
kamen69954y@Farah Tasks like this are designed to give you an intro to a language you don't yet know by having you deal with a simple enough problem. If you fail here, you're going to have a really bad time onwards.
-
vane112804yTheoretically you can’t measure area of circle. You can only approximate it right now.
Because error rate is so small we tell people we can do it but in fact we’re not able to calculate it without using constraint that was brought by ancient Egyptians on papyrus. -
@vane So we can measure the area of a circle if we move the irrationality to the radius in the right way.
-
vane112804y@Fast-Nop you can’t measure but only approximate. Same as square root of 2. We get that for granted but it’s limitation of number system we’re using. There are at least two paradoxes around circle/sphere so I believe our math is fundamentally broken but nobody gives a shit. Bertrand or Banach-Tarski paradox.
Same as most of us think earth is round but get for granted that we live in Euclidean geometry. But in fact we live in spherical one lol -
@vane Let r=1/sqrt(pi). Then a=pi*r^2=1, which is a rational number. Sure, then we can't measure the radius, but your statement was only about the area.
-
vane112804y@Fast-Nop ok so what is pi then ? How much it is exactly ? For me it’s real number with infinite precision. Based on that we can have infinite number of solutions that are limited by precision of PI
-
vane112804y@Fast-Nop I go further you can say I’m stupid cause you can take and measure circle in real life but it’s illusion cause your measure have precision and also meter definition is based on vacuum speed of light and as we know speed of light is constraint that is approximated.
-
@vane Given the Planck time as minimum time quantum, that translates into length not actually being a continuous variable, but a discrete one, albeit with extremely high resolution. This means that we ultimately cannot even measure the radius itself anyway.
-
dder23234yHave you tried the following ?
let a = Math.areaCircle(r);
let c = a - 1;
return c++; // since c++ is required
Related Rants
-
devJs0fellow from the team was asked to do the estimate by manager - he said 2 weeks then manager asked what if we...
-
dimsumexception1When I saw the U-Boot prompt on the console of a system that we'd developed from scratch all from openly avail...
-
ScriptCoded6A certain team member left the team
Calculate the area of circle by C++
question
wk222