Assignment 1
Assignment 1
Assignment 1
Marks: 10 Sec: 11, 12 Submission Date: 11:59 pm, 10 th Dec
Sample Input:
A [] = [-2, 12, 45, -9, 1, 5, 12, -2]
Sample Output:
-9, -2, 1, 5, 12, 45
3. Write a function to compute the distance between two points (points are
given by the user), and use it to develop another function that will compute
the area of the triangle whose vertices are A(x1, y1), B(x2, y2), and C(x3,
y3).
Use these functions to develop a function which returns a value 1 if the point
(x, y) lines inside the triangle ABC, otherwise a value 0.
Sample Outputs:
The total number of vowel in the string is : 5
The total number of consonant in the string is : 9
Filtered String: A=Q78U*ic?K!b$R(Ow/Nf%o#x
5. Given a string, that contains alphabets (‘a’ to ‘z’ and ‘A’ to ‘Z’), write a
function to print string by inserting the frequency of each unique character
after it and also eliminating all repeated characters.