Finding of the 4 larger (bigger) numbers from the list
like{1245,4587,2145,1163,29987,65783.....}
Answer / santhosh
int Max = 4;
List<int> lst = new List<int>(new int[] { 1, 12,
2, 11, 15, 3, 14, 4, 5, 6, 7, 8, 9, 10 });
lst.Sort();
if (Max <= lst.Count)
Console.WriteLine(string.Format("The {0} th
Maximum value is {1}.", Max, lst[lst.Count - Max]));
else
Console.WriteLine(string.Format("This list
contain less items. So you could not find the {0}th highest
value from the list.", Max));
Is This Answer Correct ? | 1 Yes | 1 No |
how to get the oracle certification? send me the answer
What is difference between inheritance and polymorphism?
What is Hashing and how is it done? Pictorial form?
can inline function declare in private part of class?
What is the importance of oop?
Do you know about multiple inheritance?
What is a linked list?
write a program using c++ to implement single contiguous memory mangement techniques.display the content of the main memory after yhe allocation of jobs and percentage of the wastage of the main memory
What is the important feature of inheritance?
how to swap to variables without using thrid variable in java?
Why do we use encapsulation in oops?
1.explicit call for destructor 2.calling function inside a constructor. 3.base *b-new derived delete b; 4.delete p what it will delete. 5.size of base class and derived class int i,in base class and int j in derived. 6.int i-20 int main() { int i =5; printf("%d".::i); { int i =10; printf("%d".::i); } } 7.object slicing 8.new 9.function overloading(return type). 10.class base() { virtuval fun() { ----- } } class derivied:public base() { fun() { ----- } } int main() { derived d; } 11.how static function will call in C++? 12.default structures are in C++? 13.constructors should be in public . 14.virtuval constructor not exist. 15.multilevel inhritence. destructor order.