تبلیغات
دانلود سورس پروژه های مختلف برنامه نویسی، آموزش برنامه نویسی - جستجوی خطی با آرایه
دانلود سورس پروژه های مختلف برنامه نویسی، آموزش برنامه نویسی
دانلود رایگان سورس پروژه
سایت برنامه نویسی تک کدر takcoder.ir


آموزش برنامه نویسی با استفاده از نوین ترین روش و ارائه پروژه های نمونه و مجموعه عظیم سورس کدهای آماده برای شما دوستان

مدیر سایت : Yahya Taherzadeh
نویسندگان
نظرسنجی
زبان برنامه نویسی مورد علاقه شما؟






سلام دوستان عزیز

برای شما جستجوی خطی با آرایه را می گذارم، این سورس کد  که به زبان سی پلاس پلاس نوشته شده است در واقع سورس الگوریتم جستجوی خطی می باشد.

#include<iostream.h>
#include<conio.h>

int lsearch(int Arr[], int s, int VAL);

int main()
{
int Arr[100],n,val,found;
cout<<”Enter number of elements you want to insert “;
cin>>n;
for(int i=0;i<n;i++)
{
cout<<”Enter element “<<i+1<<”:”;
cin>>Arr[i];
}

cout<<”Enter the number you want to search “;
cin>>val;

found=lsearch(Arr,n,val);

if(found==1)
cout<<”\nItem found”;
else
cout<<”\nItem not found”;

getch();
return 0;
}

int lsearch(int Arr[], int s, int VAL)
{
for(int I=0; I<s; I++)
{
if(Arr[I]==VAL)
return 1;
}
return 0;
}





نوع مطلب : آموزش، پروژه های رایگان، سی| سی پلاس پلاس، پروژه های تکمیل شده، 
برچسب ها : جستجوی خطی با آرایه، جستجوی خطی با آرایه در سی پلاس، سی پلاس، دانلود رایگان کد، کدهای، کدهای آماده برنامه نویسی، دانلود مطالب برنامه نویسی،
لینک های مرتبط :
Yahya Taherzadeh
چهارشنبه 20 آذر 1392
پنجشنبه 19 مهر 1397 05:21 ب.ظ
Fantastic goods from you, man. I have be aware your stuff previous to and
you're simply too wonderful. I really like what you have got here, really like
what you're stating and the best way through which you are saying it.
You're making it entertaining and you continue to take care of to
stay it wise. I can't wait to read far more from you.
This is really a wonderful web site.
چهارشنبه 18 مهر 1397 02:02 ب.ظ
Thank you for sharing your info. I really
appreciate your efforts and I am waiting for your next write ups thank you once again.
دوشنبه 16 مهر 1397 02:00 ب.ظ
constantly i used to read smaller articles which also clear their motive, and that is also happening with this
piece of writing which I am reading here.
دوشنبه 16 مهر 1397 01:33 ب.ظ
Hey there, I think your blog might be having browser compatibility issues.
When I look at your blog in Opera, it looks fine but when opening in Internet Explorer, it has some
overlapping. I just wanted to give you a quick heads up! Other then that, awesome blog!
یکشنبه 15 مهر 1397 09:03 ب.ظ
I do not even know how I ended up here, but I thought this post
was great. I don't know who you are but certainly you're going to a famous blogger if you
aren't already ;) Cheers!
شنبه 14 مهر 1397 12:13 ق.ظ
I'm curious to find out what blog system you're working with?
I'm having some small security problems with my latest blog and I'd like to find something more safe.
Do you have any solutions?
سه شنبه 10 مهر 1397 10:18 ق.ظ
Excellent article. I'm dealing with some of these issues
as well..
سه شنبه 10 مهر 1397 08:05 ق.ظ
Good post. I'm experiencing a few of these issues as well..
سه شنبه 10 مهر 1397 05:00 ق.ظ
This excellent website definitely has all the info I wanted about this subject and didn't know
who to ask.
یکشنبه 1 مهر 1397 05:57 ب.ظ
Excellent article! We will be linking to this particularly
great content on our site. Keep up the great writing.
شنبه 24 شهریور 1397 12:43 ب.ظ
Just want to say your article is as amazing.
The clearness in your post is simply nice and i could assume you're an expert on this
subject. Fine with your permission let me to grab your RSS feed to keep up
to date with forthcoming post. Thanks a million and please keep up the rewarding work.
دوشنبه 25 تیر 1397 01:43 ق.ظ
I'm cսrious to find out what blog plɑtform you're using?

I'm havіng some minor security issues with my latest
sіte and I ѡould liқe to find something more risk-free.
Do youu have any suggestions?
سه شنبه 17 مرداد 1396 07:02 ق.ظ
Right away I am going away to do my breakfast, once having my breakfast coming again to read
further news.
دوشنبه 12 تیر 1396 08:47 ب.ظ
Hello my loved one! I wish to say that this post is amazing,
nice written and include almost all important infos.

I'd like to see more posts like this.
یکشنبه 11 تیر 1396 06:43 ق.ظ
Inspiring story there. What happened after?
Thanks!
شنبه 3 تیر 1396 03:51 ب.ظ
Good day very nice web site!! Guy .. Excellent
.. Superb .. I will bookmark your website and take the feeds
also? I'm glad to seek out numerous useful information right here in the
publish, we'd like develop more strategies in this regard, thank you for sharing.
. . . . .
چهارشنبه 31 خرداد 1396 05:58 ب.ظ
This is the right web site for everyone who would like to understand this topic.
You know a whole lot its almost tough to argue with you (not that I really would
want to?HaHa). You definitely put a fresh spin on a topic which
has been written about for many years. Great stuff, just excellent!
یکشنبه 24 اردیبهشت 1396 03:30 ب.ظ
Hello! This is my first visit to your blog! We are a collection of volunteers and starting a new project in a community in the same niche.
Your blog provided us useful information to work on.
You have done a marvellous job!
شنبه 16 اردیبهشت 1396 09:21 ب.ظ
Undeniably believe that which you stated.
Your favorite justification seemed to be at the internet the easiest factor to
keep in mind of. I say to you, I definitely get annoyed whilst folks think about issues that they plainly do not
recognize about. You controlled to hit the nail upon the highest and defined out the whole thing without having side effect , people
can take a signal. Will probably be back to get more.
Thank you
چهارشنبه 13 اردیبهشت 1396 06:50 ب.ظ
What's up every one, here every one is sharing these knowledge, thus it's nice to read this webpage, and I used to
go to see this website daily.
چهارشنبه 13 اردیبهشت 1396 05:54 ب.ظ
I every time spent my half an hour to read this web site's articles or reviews every day along with a mug of coffee.
یکشنبه 27 فروردین 1396 11:27 ب.ظ
I was curious if you ever considered changing the layout of your website?
Its very well written; I love what youve got to say.
But maybe you could a little more in the way of content
so people could connect with it better. Youve got an awful
lot of text for only having 1 or 2 pictures. Maybe
you could space it out better?
جمعه 25 فروردین 1396 07:43 ب.ظ
hello there and thank you for your information –
I have definitely picked up anything new from
right here. I did however expertise several technical issues using this site, since I experienced to reload the
site a lot of times previous to I could get it to load properly.
I had been wondering if your hosting is OK? Not that I'm complaining, but slow loading instances
times will often affect your placement in google and could damage your quality score if
ads and marketing with Adwords. Well I am adding this
RSS to my email and could look out for much more of your respective intriguing content.
Make sure you update this again very soon.
جمعه 18 فروردین 1396 06:10 ب.ظ
For most up-to-date information you have to go to see web and on the web I
found this website as a best site for most recent updates.
 
لبخندناراحتچشمک
نیشخندبغلسوال
قلبخجالتزبان
ماچتعجبعصبانی
عینکشیطانگریه
خندهقهقههخداحافظ
سبزقهرهورا
دستگلتفکر




صفحات جانبی
آمار وبلاگ
تاییدیه پرداخت
تبلیغات
به سایت تک کدر خوش آمدید