Let it be known, for i am currently a freshman in IT and I shall come back when I've graduated (hopefully) to thank you once again for the aid you've given me. This tutorial shall be one of the many steps I'll use to attain greatness, so for now, thank you.
THANK YOUU !! back when I'm in semester 1 learning statics you saved me by teaching trusses analysis and now you saved me again by teaching c++ , you really are the best, thank you =) really appreciate it !!
Thank you sooo much, I always asked why we initialized the max or min to the first element of the array and when I asked someone there answer is always to find the max, but now I finally know thanks
i'm assuming you figured it out but i was able to put something together. if you find a better way please reply int max {0}; int arr[5]; for(size_t i{0}; i < 5; i++){ coutarr[i]; } cout
Yeah thanks for this. I didn't try running it but the concept looks right. Use a loop to have the user input to the array then use another loop after to do the check 🙂
The array has to always be a set number. The user can go below but not above that set number so you would use this example in exactly the same way. The only change would be to the five when you initialize the array. The five would change to however big you want your array to be.
Mmmm did you not notice though that I changed the variable name and multiple other lines. The code that finds and outputs the max is different than the code that finds and outputs the min.
Yeah it should. See video 40 here: engineer4free.com/cplusplus and also consider using vectors of vectors if you're allowed to (which are the topic of videos 41 - 47)
awesome! now...how to identify which element is the max, meaning the output would say something to the effect of, "it is the third element," or output 3 in this case since 8 is the largest element and it is the 3rd element. thank you
What if I don't know what the user will input? Should I create an integer to compare all the inputs to that?!(I am pretty sure it's not gonna work though!)
@@Engineer4Free thankyou!! I will check those out. I don't suppose you know how I would display the element position of a max or min value in a 2d array? sorry if its a really silly question but I've been stuck on this for ages. Thanks heaps!!
Я рад, что видео помогает. Спасибо за просмотр! Я вообще не говорю по-русски, мне пришлось использовать перевод Google :p I'm glad that the video helps. Thanks for watching! I don't speak any Russian, I had to use Google Translate: p
Let it be known, for i am currently a freshman in IT and I shall come back when I've graduated (hopefully) to thank you once again for the aid you've given me. This tutorial shall be one of the many steps I'll use to attain greatness, so for now, thank you.
THANK YOU!!! YOU SAVED ME FOR MY ASSIGNMENT DUE TONIGHT LOL
Gochu 🤜🤛
THANK YOUU !! back when I'm in semester 1 learning statics you saved me by teaching trusses analysis and now you saved me again by teaching c++ , you really are the best, thank you =) really appreciate it !!
Amazing!!! Glad I can keep helping you out my friend =) =)
concept was very nicely explained, thank you, keep it up 👍👍🙂🙂
Thanks SP ;) ;)
Honestly your approach here made my life easier.Thanks a lot.
Amazing. Really glad to hear it! You might wanna check out all the other C++ videos that I did here: engineer4free.com/cplusplus 😊
you hav e saved me from my confusion thank you
Glad to help!! Full C++ playlist is down in the description! 😁
Thank you sooo much, I always asked why we initialized the max or min to the first element of the array and when I asked someone there answer is always to find the max, but now I finally know thanks
Glad I could clear that up for you!
Cobol equivalent code:
Working-storage section.
01 save-num pic 9(2) value 0.
01 W-num-TABLE.
04 W-num OCCURS 5 TIMES
INDEXED BY W-num-NDX.
10 num-array PIC 9(2).
88 num1 VALUE 02.
88 num2 VALUE 04.
88 num3 VALUE 08.
88 num4 VALUE 01.
88 num5 VALUE 06.
procedure division.
perform varying w-num from 1 by 1 until w-num-ndx > 5
if num-array (w-num-ndx) > save-num
move num-array (w-num-ndx) to save-num.
display 'max number ' save-num.
Cool, thanks!!
this was such a smart approach, how did i no think about this.
Thanks, glad you liked it!
i was searching a totally different tutorial, but some tutorial of basic things is good
Glad you liked it! Many more similar tutorials here: engineer4free.com/cplusplus =)
how do i show both max and min at the same time?
YOU ARE BRILLIANT AND I LOVE YOU SO MUCH AND THANK YOU FOR EXISTING
THANKS HANA. I’M GLAD YOU EXIST TOO ✨
Engineer4Free THANK YOU SO MUCH AND STAY AWESOME 🥺
Wow! This is very straight forward. Thanks so much.
You're welcome! Full playlist is at engineer4free.com/cplusplus 🙂
@Engineer4Free , what is the name of the IDE you are using ?
Xcode 👨💻
How do you do you get the max and min of an array where the user inputs all the values?
the same code will apply bro, just assume the first value at 0 index is largest among all then run a loop till the array length with a if condition.
i'm assuming you figured it out but i was able to put something together. if you find a better way please reply
int max {0};
int arr[5];
for(size_t i{0}; i < 5; i++){
coutarr[i];
}
cout
Yeah thanks for this. I didn't try running it but the concept looks right. Use a loop to have the user input to the array then use another loop after to do the check 🙂
The array has to always be a set number. The user can go below but not above that set number so you would use this example in exactly the same way. The only change would be to the five when you initialize the array. The five would change to however big you want your array to be.
I'm currently learning C but this helped too, thanks.
Glad to hear it!!
hello do you have a tutorial about swapping???
Unfortunately no. But you can check out all the videos that I made here: engineer4free.com/cplusplus
Thank you man !! helped me a lot
awesome glad to hear it!
No one book of Debugger can learn to understated the code as read human being explain it step by step. Thanks.
what compilator are u using? its very helpful for begginers
The IDE that you see in this video is called XCode
i'm a developer my self and that is a good job.. (Y)
Thank you!!! This really helps and it works well!
You're welcome!!!
Would this be an example of a linear search algorithm?
best explanation ever
Thanks Amina!
what IDE program do you use?
Xcode
@@Engineer4Free thanks man
Simple smart and intellect, thanks for sharing this with us!
Thank you thank you, dumbed it down for a newb.
Glad you found it useful!! 🙂
How about when using classes and objects ?🤔
What compiler are you using?
I used Xcode as my IDE in these videos
Simple and perfect explanation
how to output both min and max in one console?
Mmmm did you not notice though that I changed the variable name and multiple other lines. The code that finds and outputs the max is different than the code that finds and outputs the min.
It was so simple, meanwhile I was trying to compare every element in the array. Feels like I'm dumb xD
Thanks GOD bless you for using it to solve an exam question for me.
happy to help! :)
would this method work with a 2D array that was filled with a file? Of course adding and changing a few things
Yeah it should. See video 40 here: engineer4free.com/cplusplus and also consider using vectors of vectors if you're allowed to (which are the topic of videos 41 - 47)
@@Engineer4Free thank you, if only I was allowed to use vectors 😂, I wouldn't be 50+ hours into this homework.
thank you the video was very clear
Glad to hear it, thanks for commenting!
Quick question what application are you using to code? it looks neat
Xcode. You can see all the hardware and software that I use here: engineer4free.com/tools ✌️
Ooo ok thank you!
Very simple and clear
Thanks
Thanks for letting me know =)
Thank you! Very helpful.
You're welcome!! =)
can you help how to find a local min?
your explanation is perfect! thanks a lot
Awesome! Thanks for letting me know =)
My teacher wants the one without arrays... How do I do that?
std::cout
awesome! now...how to identify which element is the max, meaning the output would say something to the effect of, "it is the third element," or output 3 in this case since 8 is the largest element and it is the 3rd element. thank you
yess please i wanna know this too
does this work with c as well?
how to find 2nd largest num?
How could we show that max or min number is at which location of array.....
Yes you could definitely do it with another variable or two
Thanks for video..could u plz tell me how can i write elements between max and min in an another array? Thanks again!!
Thank you soooo mich.
Explained very well.
What if I don't know what the user will input?
Should I create an integer to compare all the inputs to that?!(I am pretty sure it's not gonna work though!)
Mmmm this operation can still work after the user has inputed, as the values will be set then, just not before.
Excellent Explanation!
which IDE you're using ?
Hey Anas I use Xcode, there is a link to download it at engineer4free.com/tools Thanks for watching!
Engineer4Free Thanks :)
easy to understand thanks!
Awesome, glad I could help Frankie!
Thanks a lot sir keep going
Can we find both of the max and min value in the same program?
ofc
what I do if he required max value located at diagonal in 2-D array?
THANK YOU SOOOOO MUCH MAN!!!! :-)
thanks so much for this
Hey you're welcome, glad you found it useful! I did a whole playlist on C++ that you might like, you can check it out at engineer4free.com/cplusplus
@@Engineer4Free thankyou!! I will check those out. I don't suppose you know how I would display the element position of a max or min value in a 2d array? sorry if its a really silly question but I've been stuck on this for ages.
Thanks heaps!!
This will just spit out the maximum value it doesn't necessarily tell you which sensor that gave you the data (max value).
Yes
This program run only looking for the min value in an array. How about the max value?
At 4:48 this program prints the max value of the array to the screen.
oh yeah, this program is quite nice.
Good job
Thanks Ashok!!
life saver! Thank you for using plain english xD
I gochu! =)
thanks excellent tutorial
Thanks for commenting, glad you found it helpful!
for loop will run only 4 times
it should run 5 times
so i should be smaller than 6
:)
You are right. Check my Cobol equivalent code above.
that's great! i like this lesson :) you helped me very good today :)
+auksė levonaitė Glad to hear it! You can find the rest of the C++ tutorials I made here: www.engineer4free.com/cplusplus :)
Helpful af
Awesome, glad to hear it!
which compiler is this??
I used Xcode as my IDE. Full list of my hardware and software is here: engineer4free.com/tools
thanks for replying but why isn't is compatible with windows
It's a Mac product. Here's a pretty good list of many different options that are out there www.stroustrup.com/compilers.html
Этот мужик настолько хорош, что я не слова не понимая по английски, во всем разобрался благодаря ему.
Я рад, что видео помогает. Спасибо за просмотр! Я вообще не говорю по-русски, мне пришлось использовать перевод Google :p
I'm glad that the video helps. Thanks for watching! I don't speak any Russian, I had to use Google Translate: p
write a c++ program to sort a numeric array and string array
Plz provide ans of this🙏🙏🙏🙏
Thanks a lot brother...
can window use IDE Xcode?
Xcode is only for Mac, but there are many windows alternatives: alternativeto.net/software/xcode/?platform=windows
THANK YOU A LOT
YOU'RE WELCOME A LOT
Thanks bro.
You're welcome bruddah
THANK YOU!! :')
Thank you so much sir.
finaly get it
Idle name please
Xcode. All the hardware and software that I use can be found at engineer4free.com/tools 👍👍
next tie jus put the code in the description thx
Annoying as it is, I think its good practice to type these short examples out from scratch. Thanks for watching!
thank you sooo much
This is not working in visual studio studio
that is amazing
Thanks Jianhao, glad you like it =)
Nicccccccceeee
🙂
Sunder Pichai?? 🤔😄
Thanks a lot!
Thanks Bro
You’re welcome!! 🙂
thanx a lot!
You're welcome!!