dave on Nostr: float triangleArea(float a, float b, float c){ float s, area; s = (a + b + c) / 2; ...
float triangleArea(float a, float b, float c){
float s, area;
s = (a + b + c) / 2;
area = sqrt(s * (s - a) * (s - b) * (s - c));
return area;
}
Published at
2023-02-09 10:02:05Event JSON
{
"id": "1fa5c6293ebe4756a83718c450a442e0117bc29e9500d8770b72867752565d78",
"pubkey": "5c10ed0678805156d39ef1ef6d46110fe1e7e590ae04986ccf48ba1299cb53e2",
"created_at": 1675936925,
"kind": 1,
"tags": [
[
"e",
"66241e56deba75249efa2df737b6295136ce420958ec8ee7fc4a4d6d0d83515e",
"",
"reply"
],
[
"p",
"fc1f22759d1fd7fa31bab4154f54da6aecdaeff3bada89236e0e099e0a2839e9"
]
],
"content": "float triangleArea(float a, float b, float c){\n\tfloat s, area;\n\ts = (a + b + c) / 2;\n\tarea = sqrt(s * (s - a) * (s - b) * (s - c));\n\treturn area;\n}",
"sig": "08c9a04609a5f2fea52e70779948a48eba6365b7afce3bba1389eb7b7cce98b4f8f947c896ee3f5bb1c9b8f0fadf47d20f53f874b9a1938ca895ebc17d8a1324"
}