Site Message
Only Premium Users can view the Question
Given a string, decode it following the steps mentioned below
The value range of A to Z is 65 to 90
The value range of a to z is 97 to 122
The value of space is 32
Input:
encoded string = '23511011501782351112179911801562340161171141148'
output:
Truth Always Wins
Given 3 points a(x1,y1), b(x2, y2), c(x3, y3) check if they form a non-degenerate triangle or not. If they do form a triangle then check if points p(xp, yp) and q(xq, yq) lie inside or on the triangle.
Return
Question1
Overview
Solution
reverse(str.begin(),str.end())
.num = num * 10 + (str[i] - '0');
Question 2
Overview
Solution
A = [ x1(y2 – y3) + x2(y3 – y1) + x3(y1-y2)]/2 .
XYZ triangle that is A1=>PYX,A2=>PYZ,A3=> PXZ.
A1 + A2 + A3 must be equal to A.