Thanks so much! This helped me understand linear search more clearly via code. Currently learning data structures & algorithms for potential jobs. C++ is my go-to language; it really helps me think.
H,i how could you construct a program to perform a linear search for a string within another string not using the find function. all of the examples use int which is fairly easy.
Hi I am really searching for this and I hope to see it someday soon. what if I have to enter a few characters and the search returns all similar texts or sentences in a stored array Please Terry if you find it, do let me know here, I will be on the lookout.
he thanks for your videos.could you make a video about the Big O notation and complexity. I really don't understand what they mean and how I can use it.
Very helpful! Thank you. One thought. In determining if the number was found or not, you used if (results > 0). This would only work if the array was unsigned int. If the array consisted of negative numbers, it wouldn't work. so wouldn't it be necessary to declare the array appropriate? I guess in the case, you can check if the result !==-1, return "Number was found."
Videos are great ;)) .... But iam wondering how long will it take for a modern pc to loop through an array[1000000] using a linear search to find a specific number .. ??? Any idea ?? ... Is there any way to calculate time that linear searches will take ??
Fahad Mirza i figgured it out and yea, but i made an array with random values in it. now im trying to figure out instead of -1, it returns the index of the value closest to the value. So lets say there is a random value of 54 in the array, and it is in the 3rd index, the user searches for 53 and it will return the closest value in the array to 53.
+KoolKid: here is your code: #include #include using namespace std; int main() { int array[10] = {11,51,17,21,14,31,16,91,10,81}; int userValue; int index; int distance; cout > userValue; for(int i=0; i
Hi X, Seek out big-O notation...I believe the function 0(N) will get you going in the right direction...the algorithm grows linearly in direct proportion to the size of the data set. You can take a multiple of your set size, say 10, and test the speed of that, then figure the multiple of [1000000] and the big-O funtction definitions should help you determine the actual speed.
Then how will you know how to apply the source code -_- gotta learn more than just the explanation of how it works in order to be a functional programmer.
finally, a voice over that's not Indian
i like indian accent better
fuck indian accent.
Seriously, I can't stand getting an indian accent on a programming video, even if it's the most reliable and best info being given, I'll still pass.
Ikr, it sounds so mean but at the end of the day you have to choose videos you can actually follow and understand
Lol guys I'm Indian. But ya I'm fed up too with those videos. But they are legit at least.
Thanks! Keep watching.
You do a very well job brother of explaining the concept, keep it up!!!
thanks very much I love your videos
Thanks so much! This helped me understand linear search more clearly via code. Currently learning data structures & algorithms for potential jobs. C++ is my go-to language; it really helps me think.
What if you didn’t know what was gonna be in the array, how you initialize it
you use a vector, and every variable that you get you do push_back for inserting it in the vector
H,i how could you construct a program to perform a linear search for a string within another string not using the find function. all of the examples use int which is fairly easy.
Hi I am really searching for this and I hope to see it someday soon.
what if I have to enter a few characters and the search returns all similar texts or sentences in a stored array
Please Terry if you find it, do let me know here, I will be on the lookout.
Wow, your teaching style is a piece of cake.
Thanks for watching from Ethiopia.
Great tutorials ! Thank you so much for aharing the knowledge and great manner of actually "teaching" the subject matter.
#include
#include
using namespace std;
int main()
{
int access = 0, searchnum, arr = 6, num, answer;
int nums[] = {4, 8, 15, 16, 23, 42};
cout searchnum;
for(int i = 0; i < arr; i++){
num = nums[access];
if(nums[i] == searchnum){
answer = i+1;
}
}if(answer
god i love it ,, thank god not indian
How would you do a multi-dimensional array search?
You explain better than my professor
thank you very much
the way you explain things is simple and very helpful
he thanks for your videos.could you make a video about the Big O notation and complexity. I really don't understand what they mean and how I can use it.
+Persian771 : Check Derek Banas's video abt Big O Notations
Thanks your explaination simple and easy ❤
Search engine p project bna dein plz
Thank you so much...................................
Very helpful! Thank you. One thought. In determining if the number was found or not, you used if (results > 0). This would only work if the array was unsigned int. If the array consisted of negative numbers, it wouldn't work. so wouldn't it be necessary to declare the array appropriate? I guess in the case, you can check if the result !==-1, return "Number was found."
You're very clear with what you're saying and doing :D Thankyou!
thanks bruh
dude u nailed it!
You do a very well job brother of explaining the concept, keep it up!!!
Seems like I'm a bit late
Does anyone know how to search a .txt file using a linear search??????????????
Thank you so much
Why i got errors
You shouldn't have to pass in the size of the array as an input parameter,, you can calculate that in the function.
very nice tutorial
Thank you
wow.. I like this song..
Have a question, why "size" doesn't need to declare first in somewhere before you put it in the function?
Videos are great ;)) .... But iam wondering how long will it take for a modern pc to loop through an array[1000000] using a linear search to find a specific number .. ??? Any idea ?? ... Is there any way to calculate time that linear searches will take ??
better than paid udemy courses
very nice video. clear and easy to follow. Thank you!
Clear,Precise and perfect ;)
Will watch your other videos as well
How can i do this with strings instead of numbers
string instead of int, getline cin.
still need that code?
use templates or standard library #include
Best video about this topic! thanks :)
This is good stuff by ReelLearning
gg
More please, I love these.
how do i search an array with random numbers
+KoolKid : Isn't he doing that already? Looking for a number in a array which doesn't have any order. Unless you meant something else?
Fahad Mirza i figgured it out and yea, but i made an array with random values in it. now im trying to figure out instead of -1, it returns the index of the value closest to the value. So lets say there is a random value of 54 in the array, and it is in the 3rd index, the user searches for 53 and it will return the closest value in the array to 53.
Fahad Mirza if you know how to please help.
+KoolKid: here is your code:
#include
#include
using namespace std;
int main()
{
int array[10] = {11,51,17,21,14,31,16,91,10,81};
int userValue;
int index;
int distance;
cout > userValue;
for(int i=0; i
I must thank you for the great explanation you did in this video. Thank you so much.
it is good explanation thank you very much and make linked list aligorthms just like this
Thank you very much The same program was written in a complex manner in my textbook but you have made it
pretty easier for me
Thanks a lot ! The clearest explanation ever found.
Hi X,
Seek out big-O notation...I believe the function 0(N) will get you going in the right direction...the algorithm grows linearly in direct proportion to the size of the data set. You can take a multiple of your set size, say 10, and test the speed of that, then figure the multiple of [1000000] and the big-O funtction definitions should help you determine the actual speed.
i'll spend all day trying to figure this stuff out in my book. I look watched this and no confusion got it instantly. Thank you
6:34 is the time when you should stop watching or everything he say will go over your head
Then how will you know how to apply the source code -_- gotta learn more than just the explanation of how it works in order to be a functional programmer.
thank you very much, this coding really helped me a lot through out my assignment.with clear explanation. keep it up
Thanks for making linear search easier for understanding :D keep up the good work ^^
Great video, clarity in explanation and design,,,,
how we make and call a function .
Brilliant! Thanks very much.
Easy to follow and neatly presented. Thanks!
Excellent.
Thank you.
thank u so much ..awesome
u r awesome
great
thank you very much sir :)
(Y) (Y)
is this coding valid for turbo c++
it's very good but it can be more compact and fast.