You explained this so well, and I am very thankful that you went step by step and explained more than once if you deemed necessary. Many teachers do not do this, and again, I am grateful that you do.
sir i am very grateful to you , you take my hole fear into the air😀 previously i don't know anything logic behind programming now i give interviews very confidently ❤ just one thing please make some experienced level interview programming question also THANK YOU Again from Uttar Pradesh....
package javaapplication23; import java.util.ArrayList; import java.util.Scanner; public class JavaApplication23 { public static void main(String[] args) { int[] a = {1,2,3}; int[] b = {1,2,3,4};
This playlist is the most sensible playlist on java interview programs on entire UA-cam. Thanks
You explained this so well, and I am very thankful that you went step by step and explained more than once if you deemed necessary. Many teachers do not do this, and again, I am grateful that you do.
sir i am very grateful to you , you take my hole fear into the air😀 previously i don't know anything logic behind programming now i give interviews very confidently ❤ just one thing please make some experienced level interview programming question also THANK YOU Again from Uttar Pradesh....
int[] array = {9, 80, 7, 5, 6};
Arrays.sort(array);
System.out.println("Max is: "+array[array.length-1]+'\t'+"Min is: "+ array[0]);
Thank you
Wow..👌 thanku @sultanalazzeh63 paaji❤️
Thanku You so much sir your best for increasing my programing logic.. and the playlist is very good thankyou from maharashtra..
Welcome
It is very very helpfull for beginners by your efforts somewhere someone is learning programming very effectively... thank you so much sir...
You are most welcome
Arrays.sort(a); //sorts in ascending order
Sysout(a[a.length-1]); -> max value
Sysout(a[0]); -> minimum value
but it will take: Time complexity:- O(nlog n)
Space complexity:- O(1)
how can we do it with minimum camparison.
Explanation is very very nice , easily understandable , Thank you sir!!!
which college?
Explained in a very simple way. Thanks, sir
Thank you so much for your feedback. Please share my videos with your friends or colleagues.
for i=1 , a[i]>max =30>50 -> if condition is false so it continues the loop , until if condition becomes true then , sets the max to that value
Thank you so much sir your explanation is very nice🙏🙏
Thank you Sir 🙏you explained logic very easily, I understood ❤. Keep doing Sir 🙏
Welcome
Thank u sir i didn't understand how this was possible but when you understood me then I got everything.....
You are most welcome
Here we can combine both if loop inside for loop so that with same "for" iteration we can get max and min
Fabulous teaching sir pls some more playlist on logics and dsa
Thanks
Thank you, sir... it is a very good explanation.
You are most welcome
Great explaination sir
Explained in simple way..thank you so much...sir please upload more videos on string related java programs...
Sure I will
Tnq❤
Welcome
Thank you sir!
Welcome
Amazing 🎉
Thanks
There is a 2 liner solution...
List lst = Arrays.asList(myArrayOfNumbers);
int max = Collections.max(lst);
int min = Collections.min(lst);
Here idea was to develop logic by not using any pre defined methods
You r doing great work
Thanks
🙌
Thank you sir
Welcome
Wonderful job sir!!!
thanks
very helpful video sir
Thanks
Very helpful sir
Glad to hear that
Thanku continue making videos on java plz
Thank u sir🙏
Most welcome
Thank you so much 💗
You're so welcome!
Useful Thanku
Welcome
well explained
Thanks
great video
Thanks
thank you
You're welcome
sir pls make a video in jaba 1St max,2nd max and 3rd max element from arrays
Sir please add frequently asked python programs
Coming soon.
Here for both min and Max time complexity is n^2. So is there any other solution where we can reduce time complexity?
int[] array = {9, 80, 7, 5, 6};
Arrays.sort(array);
System.out.println("Max is: "+array[array.length-1]+'\t'+"Min is: "+ array[0]);
how to find array index
class Solution{
// Function for finding maximum AND value.
public static int maxAND (int arr[], int N) {
int res=0;
for(int i=0;i
Commenting for better reach
It will not work when 3 and 6 both are missing. can you please add the solution as well
Àà
but this is so expensive and can be done much more efficiently
package javaapplication23;
import java.util.ArrayList;
import java.util.Scanner;
public class JavaApplication23 {
public static void main(String[] args) {
int[] a = {1,2,3};
int[] b = {1,2,3,4};
System.out.println(Math.max(0, a.length));
System.out.println(Math.max(0, b.length));
}
}
This code will only work if you don't have to input array elements into scanner an all your numbers are presumed to be over 0
🇮🇳🇮🇳🙏🙏👍👍
sir kindly update this list
salute
My pleasure
This playlist is the most sensible playlist on java interview programs on entire UA-cam. Thanks
Commenting for better reach