The branch of Botany which deals with the form of the plant is (a) Ecology (b) Histology (c) Physiology (d) Morphology
2 12468The radiator in an electric room heater is most effective when it is (a) Painted black (b) Painted white (c) Highly polished (d) Painted red
1 11427The first woman film star nominated to the Rajya Sabha was (a) Nargis Dutt (b) Shabana Azmi (c) Madhubala (d) Meena Kumari
9 73649. Mahatma Gandhi was referred to as ‘the Father of the Nation’ first by (a) Jawaharlal Nehru (b) Vallabhbhai Patel (c) C. Rajagopalachari (d) Subhas Chandra Bose
13 45413ITI r/tv trade APPLY (J.T.O VACANCEY) ALSO INCLUD AITT ELECTRONIC,WRITEEN XAM DONE 23.03.10 BUT NO RESPONCE WHY ANATHER ID gopal_gh007@rediffmail.com
3462Post New KBC Interview Questions
What is java lang object?
what is the probability of a complete system distortion under high end low performing multiprocessor job?
The transaction code used to create a return delivery?
What is the difference between dispose() and finalize()?
Where will find the Variants?
What is the Formula for coreletion coefficient in plhplc calibration
Is scala easy to learn?
What is syswow64 rundll32 exe?
Where is the windows recycle bin located?
Is swift based on objective c?
What is lightning data services?
What is point to point link?
What is binding (XML)?
What is tim?
You have given 2 array. You need to find whether they will
create the same BST or not.
For example:
Array1:10 5 20 15 30
Array2:10 20 15 30 5
Result: True
Array1:10 5 20 15 30
Array2:10 15 20 30 5
Result: False
One Approach is Pretty Clear by creating BST O(nlogn) then
checking two tree for identical O(N) overall O(nlogn) ..we
need there exist O(N) Time & O(1) Space also without extra
space .Algorithm ??
DevoCoder
guest
Posted 3 months ago #
#define true 1
#define false 0
int check(int a1[],int a2[],int n1,int n2)
{
int i;
//n1 size of array a1[] and n2 size of a2[]
if(n1!=n2) return false;
//n1 and n2 must be same
for(i=0;i