<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Şahabettin Akca # Saho &#187; Yazılım</title>
	<atom:link href="http://www.saho.in/category/web-yazilim/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.saho.in</link>
	<description>php, mysql, html, ajax, css,js, xml, vb, c++, c# coder</description>
	<lastBuildDate>Fri, 30 Jul 2010 08:31:45 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>lightbox ta açıklamayı üste çekip resimle yan yana koymak</title>
		<link>http://www.saho.in/lightbox-ta-aciklamayi-uste-cekip-resimle-yan-yana-koymak/</link>
		<comments>http://www.saho.in/lightbox-ta-aciklamayi-uste-cekip-resimle-yan-yana-koymak/#comments</comments>
		<pubDate>Wed, 28 Jul 2010 19:34:20 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Ajax]]></category>
		<category><![CDATA[bölme]]></category>
		<category><![CDATA[float]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[lightbox]]></category>
		<category><![CDATA[mootools]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=898</guid>
		<description><![CDATA[http://www.huddletogether.com/projects/lightbox2/#download
şu adresten lightbox u indiriyoruz .
lightbox.js yi açıyoruz
12Builder.node&#40;'div',&#123;id:'imageContainer'&#125;, &#91;
Builder.node&#40;'img',&#123;id:'lightboxImage'&#125;&#41;,
ile
123Builder.node&#40;'div',&#123;id:'imageContainer',style:'width:100%;'&#125;, &#91;
Builder.node&#40;'img',&#123;id:'lightboxImage',style:'width:50%;float:left;'&#125;&#41;,
Builder.node&#40;'span',&#123;id:'caption',style:'font-size:9px;height:10px;width:50%;float:left;'&#125;&#41;,
kodlarını değiştiriyoruz.
]]></description>
			<content:encoded><![CDATA[<p>http://www.huddletogether.com/projects/lightbox2/#download</p>
<p>şu adresten lightbox u indiriyoruz .</p>
<p>lightbox.js yi açıyoruz</p>
<div class="codecolorer-container javascript default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br /></div></td><td><div class="javascript codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Builder.<span style="color: #660066;">node</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'div'</span><span style="color: #339933;">,</span><span style="color: #009900;">&#123;</span>id<span style="color: #339933;">:</span><span style="color: #3366CC;">'imageContainer'</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span> <span style="color: #009900;">&#91;</span><br />
Builder.<span style="color: #660066;">node</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'img'</span><span style="color: #339933;">,</span><span style="color: #009900;">&#123;</span>id<span style="color: #339933;">:</span><span style="color: #3366CC;">'lightboxImage'</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span></div></td></tr></tbody></table></div>
<p>ile</p>
<div class="codecolorer-container javascript default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br /></div></td><td><div class="javascript codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Builder.<span style="color: #660066;">node</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'div'</span><span style="color: #339933;">,</span><span style="color: #009900;">&#123;</span>id<span style="color: #339933;">:</span><span style="color: #3366CC;">'imageContainer'</span><span style="color: #339933;">,</span>style<span style="color: #339933;">:</span><span style="color: #3366CC;">'width:100%;'</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span> <span style="color: #009900;">&#91;</span><br />
Builder.<span style="color: #660066;">node</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'img'</span><span style="color: #339933;">,</span><span style="color: #009900;">&#123;</span>id<span style="color: #339933;">:</span><span style="color: #3366CC;">'lightboxImage'</span><span style="color: #339933;">,</span>style<span style="color: #339933;">:</span><span style="color: #3366CC;">'width:50%;float:left;'</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span><br />
Builder.<span style="color: #660066;">node</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'span'</span><span style="color: #339933;">,</span><span style="color: #009900;">&#123;</span>id<span style="color: #339933;">:</span><span style="color: #3366CC;">'caption'</span><span style="color: #339933;">,</span>style<span style="color: #339933;">:</span><span style="color: #3366CC;">'font-size:9px;height:10px;width:50%;float:left;'</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span></div></td></tr></tbody></table></div>
<p>kodlarını değiştiriyoruz.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/lightbox-ta-aciklamayi-uste-cekip-resimle-yan-yana-koymak/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Php de __set , __get methodlarını güvenli olarak kullanmak</title>
		<link>http://www.saho.in/php-de-__set-__get-methodlarini-guvenli-olarak-kullanmak/</link>
		<comments>http://www.saho.in/php-de-__set-__get-methodlarini-guvenli-olarak-kullanmak/#comments</comments>
		<pubDate>Thu, 15 Jul 2010 21:13:41 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Php]]></category>
		<category><![CDATA[catch]]></category>
		<category><![CDATA[exception]]></category>
		<category><![CDATA[get]]></category>
		<category><![CDATA[güvenlik]]></category>
		<category><![CDATA[oop]]></category>
		<category><![CDATA[set]]></category>
		<category><![CDATA[throw]]></category>
		<category><![CDATA[try]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=883</guid>
		<description><![CDATA[php nin oop kısmında süper methodlar olarak geçen __set , __get methodları var aslında oldukça pratik hızlı iş görüyorlar.
Fakat değiştirilmemesi veya okunmaması gereken değişkenler örneğin bir sınıfınızda
sifre değişkeni var bunu set edebilmek gerekebilir ama get etmek pek güvenli değil. siz bunu private yaptınız mesala __get sayesinde bu değişkene erişebilirler
diğer bir örnek temaDizini diye bir değişkeniniz [...]]]></description>
			<content:encoded><![CDATA[<p>php nin oop kısmında süper methodlar olarak geçen __set , __get methodları var aslında oldukça pratik hızlı iş görüyorlar.</p>
<p>Fakat değiştirilmemesi veya okunmaması gereken değişkenler örneğin bir sınıfınızda</p>
<p>sifre değişkeni var bunu set edebilmek gerekebilir ama get etmek pek güvenli değil. siz bunu private yaptınız mesala __get sayesinde bu değişkene erişebilirler</p>
<p>diğer bir örnek temaDizini diye bir değişkeniniz var bu değişken get edilmeli ihtiyaçta olacaktır, ama set edilmemeli programın / yazılımın çalışması bozulabilir.</p>
<p>C# da bu olay sadece o method bazlı olarak yapılıyor ve oldukça güvenlide bir yöntem isteğe göre düzeltebiliyorsun</p>
<p>örnek vereyim</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;code style=&quot;white-space: nowrap;&quot;&gt;&lt;code&gt;Private String sifre ;<br />
public String Sifre() {<br />
set { sifre = value;}<br />
} &lt;/code&gt;&lt;/code&gt;<br />
<br />
&lt;code style=&quot;white-space: nowrap;&quot;&gt;&lt;code&gt;Private String temaDizini;<br />
public String TemaDizini() {<br />
get{ return temaDizin; }<br />
}&lt;/code&gt;&lt;/code&gt;</div></td></tr></tbody></table></div>
<p>c# da bu şekilde kullanılıyor.</p>
<p>php de de nelerin get edilebilir nelerin set edilebileceğini pratik bir yolla şöyle yapabiliriz :</p>
<div class="codecolorer-container php default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br /></div></td><td><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span>?php<br />
<span style="color: #000000; font-weight: bold;">class</span> saho <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$yetkilerSet</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'adi'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'soyadi'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'maili'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'sifresi'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$yetkilerGet</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'adi'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'soyadi'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'temaDizini'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> __set <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$varname</span><span style="color: #339933;">,</span> <span style="color: #000088;">$value</span> <span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
try<span style="color: #009900;">&#123;</span> <span style="color: #666666; font-style: italic;">// yakalanmamış hata uyarısı almamak için böyle bir kullanımda yapılabilir.</span><br />
<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><a href="http://www.php.net/in_array"><span style="color: #990000;">in_array</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$varname</span><span style="color: #339933;">,</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>yetkilerSet<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
throw <span style="color: #000000; font-weight: bold;">new</span> Exception<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Bu islemi yapmaya yetkiniz yok&amp;lt;br /&amp;gt;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #b1b100;">else</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #000088;">$this</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span><span style="color: #009900;">&#123;</span><span style="color: #000088;">$varname</span><span style="color: #009900;">&#125;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$value</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
catch<span style="color: #009900;">&#40;</span>Exception <span style="color: #000088;">$ex</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
<br />
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;#{<span style="color: #006699; font-weight: bold;">$ex</span>-&amp;gt;getLine()} : {<span style="color: #006699; font-weight: bold;">$ex</span>-&amp;gt;getMessage()}&quot;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> __get <span style="color: #009900;">&#40;</span><span style="color: #000088;">$varname</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><a href="http://www.php.net/in_array"><span style="color: #990000;">in_array</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$varname</span><span style="color: #339933;">,</span><span style="color: #000088;">$this</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>yetkilerGet<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
throw <span style="color: #000000; font-weight: bold;">new</span> Exception<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Bu islemi yapmaya yetkiniz yok&amp;lt;br /&amp;gt;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #b1b100;">return</span> <span style="color: #000088;">$this</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span><span style="color: #009900;">&#123;</span><span style="color: #000088;">$varname</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000088;">$b</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> saho<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
try<span style="color: #009900;">&#123;</span><br />
<span style="color: #b1b100;">echo</span> <span style="color: #000088;">$b</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>x<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
catch <span style="color: #009900;">&#40;</span>Exception <span style="color: #000088;">$ex</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;#{<span style="color: #006699; font-weight: bold;">$ex</span>-&amp;gt;getLine()} : {<span style="color: #006699; font-weight: bold;">$ex</span>-&amp;gt;getMessage()}&quot;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000088;">$b</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>x<span style="color: #339933;">=</span><span style="color: #cc66cc;">3</span><span style="color: #339933;">;</span><br />
<br />
?<span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;</span></div></td></tr></tbody></table></div>
<p>set ve get edilebilecek değişkenleri bir array da saklayıp oradan süzüyor eğer izinli listesindeyse çalışmasına devam ediyor</p>
<p>izinli listesinde değilse daha güvenli bir hal almış  oldu <img src='http://www.saho.in/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>not: r10 daki bir soru üzerine r10 forumlarında cevap vermiştim göremeyenler olabilir buradan da yayınlayalım (:</p>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/php-de-__set-__get-methodlarini-guvenli-olarak-kullanmak/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>seri port tan veri okumak ve internete göndermek</title>
		<link>http://www.saho.in/seri-port-tan-veri-okumak-ve-internete-gondermek/</link>
		<comments>http://www.saho.in/seri-port-tan-veri-okumak-ve-internete-gondermek/#comments</comments>
		<pubDate>Sat, 15 May 2010 08:53:31 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Html]]></category>
		<category><![CDATA[Php]]></category>
		<category><![CDATA[Server]]></category>
		<category><![CDATA[bitirme ödevi]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[seriport]]></category>
		<category><![CDATA[webbrowser]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=832</guid>
		<description><![CDATA[Örneğin bir devreniz var bunun yaptığı işlemi internette yayınlamak istiyorsunuz bunun için, seri port veya usb yi kullanabiliriz.
Seri port ile yapmıştık ben onu tarif edeceğim pek te bir zorluğu yok zaten.
buna ek olarak seri port la alınan veriyi 5 saniye de bir göndereceğiz web e sürekli değil
bunun için seri port kısmı için C# internet ayağı [...]]]></description>
			<content:encoded><![CDATA[<p>Örneğin bir devreniz var bunun yaptığı işlemi internette yayınlamak istiyorsunuz bunun için, seri port veya usb yi kullanabiliriz.</p>
<p>Seri port ile yapmıştık ben onu tarif edeceğim pek te bir zorluğu yok zaten.</p>
<p>buna ek olarak seri port la alınan veriyi 5 saniye de bir göndereceğiz web e sürekli değil</p>
<p>bunun için seri port kısmı için <strong>C#</strong> internet ayağı için <strong>PHP </strong>kullanacağız<span id="more-832"></span></p>
<p>form oluşturuyoruz form uygulamamıza <strong>seri port,timer ve webbrowser</strong> bileşenleri ekliyoruz</p>
<p>timer1 nesnesinin <strong>interval </strong>değerini 5sn ye ye ayarlıyoruz</p>
<p>seri port un ayarlarını properties den veya form_load olayına yazabiliriz</p>
<p>form_load olayında aşağıda port.open yazmıştım o satırın hemen üzerine</p>
<p><strong>port.parity,port.portname,port.baudrate değerlerini ayarlayabilirsiniz eğer ayarlamazsanız : </strong></p>
<p><em>parity 8 , portname COM1, baud ise 9600 olarak default bu değerlere ayarlanıyor, eğer daha farklı değerlerde çalışıyorsanız bu değerleri ayarlamanız gerekir</em></p>
<p>okunan <strong>port.readLine(); </strong>ile okunan veriyi webrowser nesnesiyle web sitesine<strong> ?veri=</strong> isimli get gönderiyor</p>
<p>bunuda<strong> webBrowser1.Navigate(String Url);</strong> methoduyla yapıyoruz</p>
<p>yaz.php ve oku.php yi internet sitesine yerleştiriyoruz gelen veriyi alıp veri.txt isimli bir dosyada saklıyor oku.php ile ekranda gösterebilirsiniz bunu her türlü geliştirip bir tasarım içine oturtmak vs. size kalmış birşey işin temeli budur <img src='http://www.saho.in/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>biz yaptık gayet güzel oldu</p>
<p>birde oku.php de verinin güncellenmesi lazım onun için orayada bir meta refresh &#8211; javascript location reload fln ekleyebilirsiniz.</p>
<div class="codecolorer-container csharp default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br />48<br />49<br />50<br />51<br />52<br />53<br />54<br />55<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0600FF;">using</span> <span style="color: #008080;">System</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Collections.Generic</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.ComponentModel</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Data</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Drawing</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Linq</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Text</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Windows.Forms</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.IO.Ports</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">namespace</span> WindowsFormsApplication1<br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">partial</span> <span style="color: #FF0000;">class</span> Form1 <span style="color: #008000;">:</span> Form<br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0600FF;">public</span> Form1<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
InitializeComponent<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0600FF;">public</span> <span style="color: #FF0000;">string</span> veri<span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">public</span> SerialPort port <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> SerialPort<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">public</span> <span style="color: #FF0000;">string</span> url <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;http://www.ankabt.com/sicaklik/yaz.php?kullanici=saho&amp;amp;sifre=123456&quot;</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">public</span> <span style="color: #FF0000;">string</span> tempUrl<span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">private</span> <span style="color: #0600FF;">void</span> Form1_Load<span style="color: #000000;">&#40;</span><span style="color: #FF0000;">object</span> sender, EventArgs e<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
port.<span style="color: #0000FF;">Open</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">if</span> <span style="color: #000000;">&#40;</span>port.<span style="color: #0000FF;">IsOpen</span> <span style="color: #008000;">==</span> <span style="color: #0600FF;">true</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
port.<span style="color: #0000FF;">DataReceived</span> <span style="color: #008000;">+=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> SerialDataReceivedEventHandler<span style="color: #000000;">&#40;</span>Oku<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0600FF;">private</span> <span style="color: #0600FF;">void</span> Oku<span style="color: #000000;">&#40;</span><span style="color: #FF0000;">object</span> s, SerialDataReceivedEventArgs e<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<br />
veri <span style="color: #008000;">=</span> port.<span style="color: #0000FF;">ReadLine</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
tempUrl <span style="color: #008000;">=</span> url <span style="color: #008000;">+</span> <span style="color: #666666;">&quot;&amp;amp;veri=&quot;</span> <span style="color: #008000;">+</span> veri<span style="color: #008000;">;</span><br />
<br />
webBrowser1.<span style="color: #0000FF;">Navigate</span><span style="color: #000000;">&#40;</span>tempUrl<span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #0600FF;">private</span> <span style="color: #0600FF;">void</span> timer1_Tick<span style="color: #000000;">&#40;</span><span style="color: #FF0000;">object</span> sender, EventArgs e<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0600FF;">if</span> <span style="color: #000000;">&#40;</span>port.<span style="color: #0000FF;">IsOpen</span> <span style="color: #008000;">==</span> <span style="color: #0600FF;">true</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
port.<span style="color: #0000FF;">Close</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0600FF;">else</span><br />
<span style="color: #000000;">&#123;</span><br />
port.<span style="color: #0000FF;">Open</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>PHP Kısmında ise  :</p>
<p><strong>yaz.php içeriği</strong></p>
<div class="codecolorer-container php default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&nbsp;</div></td></tr></tbody></table></div>
<p><strong>oku.php</strong></p>
<div class="codecolorer-container php default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br /></div></td><td><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #339933;">&lt;</span>div style<span style="color: #339933;">=</span><span style="color: #0000ff;">&quot;text-align:center;border:2px dotted lighblue;&quot;</span><span style="color: #339933;">&gt;</span><span style="color: #000088;">$sicaklik</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/file_get_contents"><span style="color: #990000;">file_get_contents</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;veri.txt&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;<br />
&lt;pre&gt; <span style="color: #006699; font-weight: bold;">{$veri}</span>&lt;/pre&gt;<br />
&quot;</span><span style="color: #339933;">;</span><br />
<br />
?<span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;&lt;/</span>div<span style="color: #339933;">&gt;</span></div></td></tr></tbody></table></div>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/seri-port-tan-veri-okumak-ve-internete-gondermek/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Java ile Dizi &#8211; Array İşlemleri</title>
		<link>http://www.saho.in/java-ile-dizi-array-islemleri/</link>
		<comments>http://www.saho.in/java-ile-dizi-array-islemleri/#comments</comments>
		<pubDate>Wed, 21 Apr 2010 18:55:23 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[ahmet zengin]]></category>
		<category><![CDATA[ders]]></category>
		<category><![CDATA[ödev]]></category>
		<category><![CDATA[sakarya üniversitesi]]></category>
		<category><![CDATA[saü]]></category>
		<category><![CDATA[teknik eğitim fakültesi]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=816</guid>
		<description><![CDATA[Java da bazı dizi- array işlemlerinin yapılmasını örnekleyen bir class , yine ödev için okuldan istenmişti hazır yazmışken yayınlayayım dedim (:
aşağıdaki test.java içeriği kodların test edildiği sınıfımız
12345678910111213141516171819202122232425262728293031323334353637383940414243/**
* @author Saho
*
*/
public class test &#123;

public static void main&#40;String&#91;&#93; args&#41; &#123;
// TODO Auto-generated method stub

int&#91;&#93; a = &#123; 9, 1, 3, 5, 9, 12, 4, 6, 16, 19, 2 [...]]]></description>
			<content:encoded><![CDATA[<p>Java da bazı dizi- array işlemlerinin yapılmasını örnekleyen bir class , yine ödev için okuldan istenmişti hazır yazmışken yayınlayayım dedim (:</p>
<p>aşağıdaki test.java içeriği kodların test edildiği sınıfımız<span id="more-816"></span></p>
<div class="codecolorer-container java default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br /></div></td><td><div class="java codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
* @author Saho<br />
*<br />
*/</span><br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> test <span style="color: #009900;">&#123;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000066; font-weight: bold;">void</span> main<span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Astring+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">String</span></a><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> args<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #666666; font-style: italic;">// TODO Auto-generated method stub</span><br />
<br />
<span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> a <span style="color: #339933;">=</span> <span style="color: #009900;">&#123;</span> 9, 1, 3, 5, 9, 12, 4, 6, 16, 19, 2 <span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span><br />
<span style="color: #666666; font-style: italic;">// 1 boyutlu dizi en büyük,küçük, ortalama,sıralama,ters çevirme</span><br />
<span style="color: #666666; font-style: italic;">// işlemleri</span><br />
dizis dizi <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> dizis<span style="color: #009900;">&#40;</span>a<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #666666; font-style: italic;">// int[] diziSon = dizi.getir();</span><br />
<span style="color: #666666; font-style: italic;">// dizi.yazdir(diziSon);</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;En Büyük : &quot;</span> <span style="color: #339933;">+</span> dizi.<span style="color: #006633;">buyuk</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;En Küçük : &quot;</span> <span style="color: #339933;">+</span> dizi.<span style="color: #006633;">kucuk</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Ortalama : &quot;</span> <span style="color: #339933;">+</span> dizi.<span style="color: #006633;">ortalama</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;G.Ortalama : &quot;</span> <span style="color: #339933;">+</span> dizi.<span style="color: #006633;">geometrikOrtalama</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
dizi.<span style="color: #006633;">sirala</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #666666; font-style: italic;">// böylede kullanılabiliyor dizi yi alıp değişkene aktarabiliyor</span><br />
<span style="color: #666666; font-style: italic;">//int[] diziSirali = dizi.getir();</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;--------Sıralı Dizi&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
dizi.<span style="color: #006633;">yazdir</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;--------Ters Çevirilen Dizi&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
dizi.<span style="color: #006633;">tersle</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
dizi.<span style="color: #006633;">yazdir</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;---------------&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Sanal 2 Boyutlu Diziler&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #666666; font-style: italic;">// /2 boyutlu dizi başlangıç</span><br />
D2Dizis d2 <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> D2Dizis<span style="color: #009900;">&#40;</span>a<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> ek <span style="color: #339933;">=</span> <span style="color: #009900;">&#123;</span> 9, 11, 22, 33 <span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span><br />
d2.<span style="color: #006633;">ekle</span><span style="color: #009900;">&#40;</span>3, ek<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
d2.<span style="color: #006633;">yazdir</span><span style="color: #009900;">&#40;</span>d2.<span style="color: #006633;">getir</span><span style="color: #009900;">&#40;</span>3<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> b <span style="color: #339933;">=</span> <span style="color: #009900;">&#123;</span> 1, 2, 3, 4, 5 <span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span><br />
d2.<span style="color: #006633;">ekle</span><span style="color: #009900;">&#40;</span>5, b<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
d2.<span style="color: #006633;">yazdir</span><span style="color: #009900;">&#40;</span>d2.<span style="color: #006633;">getir</span><span style="color: #009900;">&#40;</span>5<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #666666; font-style: italic;">// 2 boyutlu dizi bitiş</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #009900;">&#125;</span></div></td></tr></tbody></table></div>
<p>bu dizis.java sınıfı dizi işlemlerinin tutulduğu sınıf</p>
<div class="codecolorer-container java default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br />48<br />49<br />50<br />51<br />52<br />53<br />54<br />55<br />56<br />57<br />58<br />59<br />60<br />61<br />62<br />63<br />64<br />65<br />66<br />67<br />68<br />69<br />70<br />71<br />72<br />73<br />74<br />75<br />76<br />77<br />78<br />79<br />80<br />81<br />82<br />83<br />84<br />85<br />86<br />87<br />88<br />89<br />90<br />91<br />92<br />93<br />94<br />95<br />96<br />97<br />98<br />99<br /></div></td><td><div class="java codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
*<br />
*/</span><br />
<br />
<span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
* @author Saho<br />
*<br />
*/</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> dizis <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> dizi<span style="color: #339933;">;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> dizis<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">this</span>.<span style="color: #006633;">dizi</span> <span style="color: #339933;">=</span> dizi<span style="color: #339933;">;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> getir<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">return</span> dizi<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">double</span> ortalama<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">double</span> toplam <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">:</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
toplam <span style="color: #339933;">+=</span> i<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
toplam <span style="color: #339933;">=</span> toplam <span style="color: #339933;">/</span> dizi.<span style="color: #006633;">length</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> toplam<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">int</span> kucuk<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> sayi <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">:</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>sayi <span style="color: #339933;">==</span> 0<span style="color: #009900;">&#41;</span><br />
sayi <span style="color: #339933;">=</span> i<span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>i <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> sayi<span style="color: #009900;">&#41;</span><br />
sayi <span style="color: #339933;">=</span> i<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> sayi<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">int</span> buyuk<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> sayi <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">:</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>i <span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;</span> sayi<span style="color: #009900;">&#41;</span><br />
sayi <span style="color: #339933;">=</span> i<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> sayi<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> tersle<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> temp <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span>dizi.<span style="color: #006633;">length</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> j <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">=</span> dizi.<span style="color: #006633;">length</span> <span style="color: #339933;">-</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span> i <span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span> i<span style="color: #339933;">--</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
temp<span style="color: #009900;">&#91;</span>j<span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> dizi<span style="color: #009900;">&#91;</span>i<span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span><br />
j<span style="color: #339933;">++;</span><br />
<span style="color: #009900;">&#125;</span><br />
dizi <span style="color: #339933;">=</span> temp<span style="color: #339933;">;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> sirala<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #666666; font-style: italic;">// TODO Auto-generated method stub</span><br />
<span style="color: #000066; font-weight: bold;">int</span> j, temp<span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span> i <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> dizi.<span style="color: #006633;">length</span> <span style="color: #339933;">-</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span> i<span style="color: #339933;">++</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
j <span style="color: #339933;">=</span> i <span style="color: #339933;">+</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>dizi<span style="color: #009900;">&#91;</span>i<span style="color: #009900;">&#93;</span> <span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;</span> dizi<span style="color: #009900;">&#91;</span>j<span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
temp <span style="color: #339933;">=</span> dizi<span style="color: #009900;">&#91;</span>i<span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span><br />
dizi<span style="color: #009900;">&#91;</span>i<span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> dizi<span style="color: #009900;">&#91;</span>j<span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span><br />
dizi<span style="color: #009900;">&#91;</span>j<span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> temp<span style="color: #339933;">;</span><br />
i <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">double</span> geometrikOrtalama<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">double</span> toplam <span style="color: #339933;">=</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">:</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
toplam <span style="color: #339933;">*=</span> i<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
toplam <span style="color: #339933;">=</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Amath+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Math</span></a>.<span style="color: #006633;">pow</span><span style="color: #009900;">&#40;</span>toplam, <span style="color: #009900;">&#40;</span>1 <span style="color: #339933;">/</span> dizi.<span style="color: #006633;">length</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> toplam<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> yazdir<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">:</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>i<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> yazdir<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">:</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>i<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span></div></td></tr></tbody></table></div>
<p>buda iki boyutlu dizileri kullanmadan 2 boyutlu dizi gibi çalışan dizi sınıfı</p>
<p>D2Dizis.java</p>
<div class="codecolorer-container java default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br /></div></td><td><div class="java codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> D2Dizis <span style="color: #000000; font-weight: bold;">extends</span> dizis <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">public</span> D2Dizis<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #666666; font-style: italic;">// TODO Auto-generated constructor stub</span><br />
<span style="color: #000000; font-weight: bold;">super</span><span style="color: #009900;">&#40;</span>dizi<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Astring+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">String</span></a><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> temp <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Astring+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">String</span></a><span style="color: #009900;">&#91;</span>dizi.<span style="color: #006633;">length</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">void</span> ekle<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> anahtar, <span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
temp<span style="color: #009900;">&#91;</span>anahtar<span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">:</span> dizi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
temp<span style="color: #009900;">&#91;</span>anahtar<span style="color: #009900;">&#93;</span> <span style="color: #339933;">+=</span> i <span style="color: #339933;">+</span> <span style="color: #0000ff;">&quot;,&quot;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> getir<span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> anahtar<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Astring+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">String</span></a><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> bol <span style="color: #339933;">=</span> temp<span style="color: #009900;">&#91;</span>anahtar<span style="color: #009900;">&#93;</span>.<span style="color: #006633;">split</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;[,]&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> t <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#91;</span>bol.<span style="color: #006633;">length</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> j <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Astring+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">String</span></a> i <span style="color: #339933;">:</span> bol<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
t<span style="color: #009900;">&#91;</span>j<span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Ainteger+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Integer</span></a>.<span style="color: #006633;">parseInt</span><span style="color: #009900;">&#40;</span>i<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
j<span style="color: #339933;">++;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> t<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span></div></td></tr></tbody></table></div>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/java-ile-dizi-array-islemleri/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>php ile dosya ve klasör listeleme</title>
		<link>http://www.saho.in/php-ile-dosya-ve-klasor-listeleme/</link>
		<comments>http://www.saho.in/php-ile-dosya-ve-klasor-listeleme/#comments</comments>
		<pubDate>Fri, 26 Mar 2010 14:59:34 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Php]]></category>
		<category><![CDATA[dirread]]></category>
		<category><![CDATA[dosya listeleme]]></category>
		<category><![CDATA[erhan]]></category>
		<category><![CDATA[fileread]]></category>
		<category><![CDATA[klasör listeleme]]></category>
		<category><![CDATA[opendir]]></category>
		<category><![CDATA[readdir]]></category>
		<category><![CDATA[shizo]]></category>
		<category><![CDATA[sort]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=793</guid>
		<description><![CDATA[php ile belirtilen klasördeki dosyaları veya klasörleri(klasör altındaki klasörleri yani ) listeleme
$sonuc = dosyaListele(&#8217;klasör adı&#8217;);
string olarak klasör adını veriyorsunuz , array olarak size dosyaları dönderiyor&#8230;
dönen arrayı foreach ile kullanabilir json ile vs kullanabilirsiniz.
12345678910111213141516171819202122232425262728function dosyaListele&#40;$klasor&#41;
&#123;
$dosyaListesi = array&#40;&#41;;
$dizin=opendir&#40;$klasor&#41;;
while &#40;$file = readdir&#40;$dizin&#41;&#41; &#123;
if &#40; $file!=&#34;.&#34; AND $file!=&#34;..&#34; AND $file!=&#34;&#34; &#41;
&#123;
$dosyaListesi &#91;&#93;=$file;
&#125;
&#125;
closedir&#40;$dizin&#41;;
sort&#40;$dosyaListesi&#41;;
return $dosyaListesi;
&#125;
function klasorListele&#40;$klasor&#41;
&#123;
$klasorListesi = array&#40;&#41;;
$dizin=opendir&#40;$klasor&#41;;
while &#40;$file = readdir&#40;$dizin&#41;&#41; [...]]]></description>
			<content:encoded><![CDATA[<p>php ile belirtilen klasördeki dosyaları veya klasörleri(klasör altındaki klasörleri yani ) listeleme</p>
<p>$sonuc = dosyaListele(&#8217;klasör adı&#8217;);</p>
<p>string olarak klasör adını veriyorsunuz , array olarak size dosyaları dönderiyor&#8230;</p>
<p>dönen arrayı foreach ile kullanabilir json ile vs kullanabilirsiniz.</p>
<div class="codecolorer-container php default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br /></div></td><td><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000; font-weight: bold;">function</span> dosyaListele<span style="color: #009900;">&#40;</span><span style="color: #000088;">$klasor</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #000088;">$dosyaListesi</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$dizin</span><span style="color: #339933;">=</span><a href="http://www.php.net/opendir"><span style="color: #990000;">opendir</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$klasor</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">while</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/readdir"><span style="color: #990000;">readdir</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$dizin</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #000088;">$file</span><span style="color: #339933;">!=</span><span style="color: #0000ff;">&quot;.&quot;</span> AND <span style="color: #000088;">$file</span><span style="color: #339933;">!=</span><span style="color: #0000ff;">&quot;..&quot;</span> AND <span style="color: #000088;">$file</span><span style="color: #339933;">!=</span><span style="color: #0000ff;">&quot;&quot;</span> <span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #000088;">$dosyaListesi</span> <span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">=</span><span style="color: #000088;">$file</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<a href="http://www.php.net/closedir"><span style="color: #990000;">closedir</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$dizin</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.php.net/sort"><span style="color: #990000;">sort</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$dosyaListesi</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">return</span> <span style="color: #000088;">$dosyaListesi</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">function</span> klasorListele<span style="color: #009900;">&#40;</span><span style="color: #000088;">$klasor</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #000088;">$klasorListesi</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/array"><span style="color: #990000;">array</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$dizin</span><span style="color: #339933;">=</span><a href="http://www.php.net/opendir"><span style="color: #990000;">opendir</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$klasor</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">while</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$file</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/readdir"><span style="color: #990000;">readdir</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$dizin</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><a href="http://www.php.net/ereg"><span style="color: #990000;">ereg</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;[.]&quot;</span><span style="color: #339933;">,</span><span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span> and <span style="color: #000088;">$file</span><span style="color: #339933;">!=</span><span style="color: #0000ff;">&quot;&quot;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #000088;">$klasorListesi</span> <span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">=</span><span style="color: #000088;">$file</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<a href="http://www.php.net/closedir"><span style="color: #990000;">closedir</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$dizin</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.php.net/sort"><span style="color: #990000;">sort</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$klasorListesi</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">return</span> <span style="color: #000088;">$klasorListesi</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span></div></td></tr></tbody></table></div>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/php-ile-dosya-ve-klasor-listeleme/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>C++ ile consolda pişti oyunu</title>
		<link>http://www.saho.in/c-ile-consolda-pisti-oyunu/</link>
		<comments>http://www.saho.in/c-ile-consolda-pisti-oyunu/#comments</comments>
		<pubDate>Sat, 20 Mar 2010 19:30:27 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C++]]></category>
		<category><![CDATA[ahmet turan özcerit]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[ödev]]></category>
		<category><![CDATA[pişti]]></category>
		<category><![CDATA[sakarya üniversitesi]]></category>
		<category><![CDATA[teknik eğitim fakültesi]]></category>

		<guid isPermaLink="false">http://www.saho.in/c-ile-consolda-pisti-oyunu/</guid>
		<description><![CDATA[C++ ile pişti , geçen dönem ödevdi onu yazmıştım fonksiyonlarla yapsam daha iyi olabilirdi ama gece yazıp maille hemen göndermem gerektiği için çokta özenmemiştim açıkcası
aslında kartlar için 2 boyutlu bir dizi yapsaymışım epey bir kod kalabalığından kurtulurmuş &#8230; neyse mühim olan not almaktı 100 almıştım zaten 
kodlar aşağıda
programın çalışan halini : www.saho.in/samples/cpp-pisti.zip adresinden indirebilirsiniz
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559#include &#60;cstdlib&#62;
#include [...]]]></description>
			<content:encoded><![CDATA[<p>C++ ile pişti , geçen dönem ödevdi onu yazmıştım fonksiyonlarla yapsam daha iyi olabilirdi ama gece yazıp maille hemen göndermem gerektiği için çokta özenmemiştim açıkcası<br />
aslında kartlar için 2 boyutlu bir dizi yapsaymışım epey bir kod kalabalığından kurtulurmuş &#8230; neyse mühim olan not almaktı 100 almıştım zaten <img src='http://www.saho.in/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /><br />
kodlar aşağıda<br />
programın çalışan halini : <a href="http://www.saho.in/samples/cpp-pisti.zip">www.saho.in/samples/cpp-pisti.zip</a> adresinden indirebilirsiniz</p>
<div class="codecolorer-container cpp default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br />48<br />49<br />50<br />51<br />52<br />53<br />54<br />55<br />56<br />57<br />58<br />59<br />60<br />61<br />62<br />63<br />64<br />65<br />66<br />67<br />68<br />69<br />70<br />71<br />72<br />73<br />74<br />75<br />76<br />77<br />78<br />79<br />80<br />81<br />82<br />83<br />84<br />85<br />86<br />87<br />88<br />89<br />90<br />91<br />92<br />93<br />94<br />95<br />96<br />97<br />98<br />99<br />100<br />101<br />102<br />103<br />104<br />105<br />106<br />107<br />108<br />109<br />110<br />111<br />112<br />113<br />114<br />115<br />116<br />117<br />118<br />119<br />120<br />121<br />122<br />123<br />124<br />125<br />126<br />127<br />128<br />129<br />130<br />131<br />132<br />133<br />134<br />135<br />136<br />137<br />138<br />139<br />140<br />141<br />142<br />143<br />144<br />145<br />146<br />147<br />148<br />149<br />150<br />151<br />152<br />153<br />154<br />155<br />156<br />157<br />158<br />159<br />160<br />161<br />162<br />163<br />164<br />165<br />166<br />167<br />168<br />169<br />170<br />171<br />172<br />173<br />174<br />175<br />176<br />177<br />178<br />179<br />180<br />181<br />182<br />183<br />184<br />185<br />186<br />187<br />188<br />189<br />190<br />191<br />192<br />193<br />194<br />195<br />196<br />197<br />198<br />199<br />200<br />201<br />202<br />203<br />204<br />205<br />206<br />207<br />208<br />209<br />210<br />211<br />212<br />213<br />214<br />215<br />216<br />217<br />218<br />219<br />220<br />221<br />222<br />223<br />224<br />225<br />226<br />227<br />228<br />229<br />230<br />231<br />232<br />233<br />234<br />235<br />236<br />237<br />238<br />239<br />240<br />241<br />242<br />243<br />244<br />245<br />246<br />247<br />248<br />249<br />250<br />251<br />252<br />253<br />254<br />255<br />256<br />257<br />258<br />259<br />260<br />261<br />262<br />263<br />264<br />265<br />266<br />267<br />268<br />269<br />270<br />271<br />272<br />273<br />274<br />275<br />276<br />277<br />278<br />279<br />280<br />281<br />282<br />283<br />284<br />285<br />286<br />287<br />288<br />289<br />290<br />291<br />292<br />293<br />294<br />295<br />296<br />297<br />298<br />299<br />300<br />301<br />302<br />303<br />304<br />305<br />306<br />307<br />308<br />309<br />310<br />311<br />312<br />313<br />314<br />315<br />316<br />317<br />318<br />319<br />320<br />321<br />322<br />323<br />324<br />325<br />326<br />327<br />328<br />329<br />330<br />331<br />332<br />333<br />334<br />335<br />336<br />337<br />338<br />339<br />340<br />341<br />342<br />343<br />344<br />345<br />346<br />347<br />348<br />349<br />350<br />351<br />352<br />353<br />354<br />355<br />356<br />357<br />358<br />359<br />360<br />361<br />362<br />363<br />364<br />365<br />366<br />367<br />368<br />369<br />370<br />371<br />372<br />373<br />374<br />375<br />376<br />377<br />378<br />379<br />380<br />381<br />382<br />383<br />384<br />385<br />386<br />387<br />388<br />389<br />390<br />391<br />392<br />393<br />394<br />395<br />396<br />397<br />398<br />399<br />400<br />401<br />402<br />403<br />404<br />405<br />406<br />407<br />408<br />409<br />410<br />411<br />412<br />413<br />414<br />415<br />416<br />417<br />418<br />419<br />420<br />421<br />422<br />423<br />424<br />425<br />426<br />427<br />428<br />429<br />430<br />431<br />432<br />433<br />434<br />435<br />436<br />437<br />438<br />439<br />440<br />441<br />442<br />443<br />444<br />445<br />446<br />447<br />448<br />449<br />450<br />451<br />452<br />453<br />454<br />455<br />456<br />457<br />458<br />459<br />460<br />461<br />462<br />463<br />464<br />465<br />466<br />467<br />468<br />469<br />470<br />471<br />472<br />473<br />474<br />475<br />476<br />477<br />478<br />479<br />480<br />481<br />482<br />483<br />484<br />485<br />486<br />487<br />488<br />489<br />490<br />491<br />492<br />493<br />494<br />495<br />496<br />497<br />498<br />499<br />500<br />501<br />502<br />503<br />504<br />505<br />506<br />507<br />508<br />509<br />510<br />511<br />512<br />513<br />514<br />515<br />516<br />517<br />518<br />519<br />520<br />521<br />522<br />523<br />524<br />525<br />526<br />527<br />528<br />529<br />530<br />531<br />532<br />533<br />534<br />535<br />536<br />537<br />538<br />539<br />540<br />541<br />542<br />543<br />544<br />545<br />546<br />547<br />548<br />549<br />550<br />551<br />552<br />553<br />554<br />555<br />556<br />557<br />558<br />559<br /></div></td><td><div class="cpp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #339900;">#include &lt;cstdlib&gt;</span><br />
<span style="color: #339900;">#include &lt;iostream&gt;</span><br />
<br />
<span style="color: #0000ff;">using</span> <span style="color: #0000ff;">namespace</span> std<span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> atilanlarCpu<span style="color: #008000;">&#91;</span>5<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> atilanlarKisi<span style="color: #008000;">&#91;</span>5<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> karo<span style="color: #008000;">&#91;</span>14<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> maca<span style="color: #008000;">&#91;</span>14<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> sinek<span style="color: #008000;">&#91;</span>14<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> kupa<span style="color: #008000;">&#91;</span>14<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
<span style="color: #0000ff;">int</span> cpuElKart<span style="color: #008000;">&#91;</span>5<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> cpuElTip<span style="color: #008000;">&#91;</span>5<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> kisiElKart<span style="color: #008000;">&#91;</span>5<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> kisiElTip<span style="color: #008000;">&#91;</span>5<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> yerElKart<span style="color: #008000;">&#91;</span>54<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> yerElTip<span style="color: #008000;">&#91;</span>54<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #008000;">&#123;</span>0<span style="color: #008000;">&#125;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">void</span> kartlariGoster<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">void</span> tipx<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">void</span> kartx<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> puanx<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span>,<span style="color: #0000ff;">int</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> kartVer<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> karistir<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> main<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> argc, <span style="color: #0000ff;">char</span> <span style="color: #000040;">*</span>argv<span style="color: #008000;">&#91;</span><span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">int</span> skorBilgisayarToplam <span style="color: #000080;">=</span> 0,skorKisiToplam <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">char</span> ad<span style="color: #008000;">&#91;</span>50<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Adinizi Giriniz : &quot;</span><span style="color: #008080;">;</span> <br />
&nbsp; &nbsp;<span style="color: #0000dd;">gets</span><span style="color: #008000;">&#40;</span>ad<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;oyunbaslangic<span style="color: #008080;">:</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">for</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> i <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span> i<span style="color: #000080;">&lt;=</span><span style="color: #0000dd;">13</span><span style="color: #008080;">;</span> i<span style="color: #000040;">++</span><span style="color: #008000;">&#41;</span> <span style="color: #666666;">// kartlar olusturuluyor ve daha once kimseye verilmedigi 1 e kurarak ile tescilleniyor</span><br />
&nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; karo<span style="color: #008000;">&#91;</span>i<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; maca<span style="color: #008000;">&#91;</span>i<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; sinek<span style="color: #008000;">&#91;</span>i<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kupa<span style="color: #008000;">&#91;</span>i<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">int</span> skorKisi <span style="color: #000080;">=</span> 0,skorBilgisayar <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">int</span> eldonus <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Bir kart cekiniz ( buyuk kart ceken oyuna ilk baslar )<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">system</span><span style="color: #008000;">&#40;</span><span style="color: #FF0000;">&quot;PAUSE&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <br />
&nbsp; &nbsp; <span style="color: #0000dd;">srand</span><span style="color: #008000;">&#40;</span><span style="color: #0000dd;">time</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">NULL</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; karistir<span style="color: #008080;">:</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> karisikKart <span style="color: #000080;">=</span> karistir<span style="color: #008000;">&#40;</span>13<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> karisikTip <span style="color: #000080;">=</span> karistir<span style="color: #008000;">&#40;</span>4<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Bilgisisayar &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; tipx<span style="color: #008000;">&#40;</span>karisikTip<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; kartx<span style="color: #008000;">&#40;</span>karisikKart<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; Cekti<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">system</span><span style="color: #008000;">&#40;</span><span style="color: #FF0000;">&quot;PAUSE&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> karisikKartx <span style="color: #000080;">=</span> karistir<span style="color: #008000;">&#40;</span>13<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> karisikTipx <span style="color: #000080;">=</span> karistir<span style="color: #008000;">&#40;</span>4<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Sizin kartiniz &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; tipx<span style="color: #008000;">&#40;</span>karisikTipx<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; kartx<span style="color: #008000;">&#40;</span>karisikKartx<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; ...<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> basla<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>karisikKart <span style="color: #000080;">&gt;</span> karisikKartx<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; basla <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Bilgisayar basliyor&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> <span style="color: #008000;">&#40;</span>karisikKart <span style="color: #000080;">&lt;</span> karisikKartx<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;basla <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Siz basliyorsunuz<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Kartlariniz aynı yeniden cekiliyor<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">goto</span> karistir<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp;<br />
<br />
<br />
&nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Kartlar karildi ve yerde 4 kart duruyor<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;<span style="color: #ff0000; font-style: italic;">/*kartVer(1);<br />
&nbsp; &nbsp;kartlariGoster(1);<br />
&nbsp; &nbsp;int atilan;<br />
&nbsp; &nbsp;while(1)<br />
&nbsp; &nbsp;{<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cin&gt;&gt;atilan;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;tipx(kisiElTip[atilan]);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cout&lt;&lt;&quot; - &quot;;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kartx(kisiElKart[atilan]);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cout&lt;&lt;endl;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;}<br />
&nbsp; &nbsp;*/</span><br />
&nbsp;kartVer<span style="color: #008000;">&#40;</span>2<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp;<span style="color: #0000ff;">int</span> atilan <span style="color: #000080;">=</span> 0,tipf,kartf,yer <span style="color: #000080;">=</span> <span style="color: #0000dd;">4</span><span style="color: #008080;">;</span><br />
&nbsp;oyun<span style="color: #008080;">:</span><br />
&nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">int</span> sayacf <span style="color: #000080;">=</span> 1,suan <span style="color: #000080;">=</span> 0,suanx <span style="color: #000080;">=</span> 0,puan <span style="color: #000080;">=</span> 0,kagitCpu <span style="color: #000080;">=</span> 0,kagitKisi <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
kartVer<span style="color: #008000;">&#40;</span>1<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
kartVer<span style="color: #008000;">&#40;</span>0<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Sizin kartlariniz : &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;kartlariGoster<span style="color: #008000;">&#40;</span>1<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>endl<span style="color: #008080;">;</span><br />
&nbsp;<span style="color: #ff0000; font-style: italic;">/*cout&lt;&lt;&quot;Pc kartlari : &quot;;<br />
&nbsp; &nbsp;kartlariGoster(0); &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp;cout&lt;&lt;endl;<br />
&nbsp;cout&lt;&lt;&quot;Yer kartlari : &quot;;<br />
&nbsp; &nbsp;kartlariGoster(2); &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp;cout&lt;&lt;endl;*/</span><br />
&nbsp; <br />
&nbsp; &nbsp;tipx<span style="color: #008000;">&#40;</span>yerElTip<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;kartx<span style="color: #008000;">&#40;</span>yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>endl<span style="color: #008080;">;</span><br />
&nbsp; &nbsp;<span style="color: #0000ff;">while</span><span style="color: #008000;">&#40;</span>1<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>basla <span style="color: #000080;">==</span> <span style="color: #0000dd;">1</span><span style="color: #008000;">&#41;</span> <span style="color: #666666;">// kullanıcı kart atıyor</span><br />
&nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yenidenAt<span style="color: #008080;">:</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Atmak istediginiz kartin rakamina basiniz : &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cin</span><span style="color: #000080;">&gt;&gt;</span>atilan<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>atilan<span style="color: #000080;">&lt;</span>1 <span style="color: #000040;">&amp;&amp;</span> atilan<span style="color: #000080;">&gt;</span>4<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Hatalı bir secim yaptiniz!<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">goto</span> yenidenAt<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">for</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> b<span style="color: #000080;">=</span><span style="color: #0000dd;">1</span><span style="color: #008080;">;</span>b<span style="color: #000080;">&lt;=</span><span style="color: #0000dd;">4</span><span style="color: #008080;">;</span>b<span style="color: #000040;">++</span><span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>atilanlarKisi<span style="color: #008000;">&#91;</span>b<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> atilan<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Hata : &quot;</span><span style="color: #000080;">&lt;&lt;</span>atilan<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; daha once atilmis!<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">goto</span> yenidenAt<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; suanx<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; atilanlarKisi<span style="color: #008000;">&#91;</span>suanx<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> atilan<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Sen : &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;tipx<span style="color: #008000;">&#40;</span>kisiElTip<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kartx<span style="color: #008000;">&#40;</span>kisiElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; Attin.&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span> <span style="color: #008000;">&#40;</span>yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span><span style="color: #000080;">==</span>kisiElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span> <span style="color: #008000;">&#41;</span> <span style="color: #000040;">||</span> <span style="color: #008000;">&#40;</span> kisiElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 11 <span style="color: #000040;">&amp;&amp;</span> yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span><span style="color: #000040;">!</span><span style="color: #000080;">=</span>0<span style="color: #008000;">&#41;</span> <span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>yer <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 11<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(Pisti X Pisti Yaptin)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;skorKisi<span style="color: #000040;">+</span><span style="color: #000080;">=</span><span style="color: #0000dd;">20</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kisiElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span> <span style="color: #000040;">!</span><span style="color: #000080;">=</span> 11<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(Pisti Yaptin)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;skorKisi<span style="color: #000040;">+</span><span style="color: #000080;">=</span><span style="color: #0000dd;">10</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(ALDIN)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(ALDIN)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yer<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElTip<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kisiElTip<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kisiElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Aldiginiz kartlar : &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">for</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> g <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span>g<span style="color: #000080;">&lt;=</span><span style="color: #0000dd;">54</span><span style="color: #008080;">;</span>g<span style="color: #000040;">++</span><span style="color: #008000;">&#41;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>g<span style="color: #000080;">&lt;=</span>yer<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kagitKisi<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; tipx<span style="color: #008000;">&#40;</span>yerElTip<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span> kartx<span style="color: #008000;">&#40;</span>yerElKart<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>g<span style="color: #000040;">!</span><span style="color: #000080;">=</span>yer<span style="color: #008000;">&#41;</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;, &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; puan <span style="color: #000080;">=</span> puanx<span style="color: #008000;">&#40;</span>yerElTip<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span>,yerElKart<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; skorKisi<span style="color: #000040;">+</span><span style="color: #000080;">=</span>puan<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElKart<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElTip<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yer <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yer<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElTip<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kisiElTip<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kisiElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #666666;">// &nbsp;cout&lt;&lt;&quot;sen alamadin devam&quot;;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; basla <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span> <span style="color: #0000ff;">else</span> <span style="color: #008000;">&#123;</span> <span style="color: #666666;">/// cpu kart atıyor</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yenidenSec<span style="color: #008080;">:</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; atilan <span style="color: #000080;">=</span> karistir<span style="color: #008000;">&#40;</span>4<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">for</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> h<span style="color: #000080;">=</span><span style="color: #0000dd;">1</span><span style="color: #008080;">;</span>h<span style="color: #000080;">&lt;=</span><span style="color: #0000dd;">4</span><span style="color: #008080;">;</span>h<span style="color: #000040;">++</span><span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>atilanlarCpu<span style="color: #008000;">&#91;</span>h<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> atilan<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">goto</span> yenidenSec<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; suan<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; atilanlarCpu<span style="color: #008000;">&#91;</span>suan<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> atilan<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Pc &nbsp;: &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;tipx<span style="color: #008000;">&#40;</span>cpuElTip<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kartx<span style="color: #008000;">&#40;</span>cpuElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; Atti.&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span> <span style="color: #008000;">&#40;</span>yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span><span style="color: #000080;">==</span>cpuElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span> <span style="color: #008000;">&#41;</span> <span style="color: #000040;">||</span> <span style="color: #008000;">&#40;</span>cpuElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 11 <span style="color: #000040;">&amp;&amp;</span> yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span><span style="color: #000040;">!</span><span style="color: #000080;">=</span>0<span style="color: #008000;">&#41;</span> <span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>yer <span style="color: #000080;">==</span> <span style="color: #0000dd;">1</span><span style="color: #008000;">&#41;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #666666;">////////</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 11<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(Pisti X Pisti Yapti)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;skorBilgisayar<span style="color: #000040;">+</span><span style="color: #000080;">=</span><span style="color: #0000dd;">20</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>cpuElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span> <span style="color: #000040;">!</span><span style="color: #000080;">=</span> 11<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(Pisti Yapti)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;skorBilgisayar<span style="color: #000040;">+</span><span style="color: #000080;">=</span><span style="color: #0000dd;">10</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(ALDI)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #666666;">///////////</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">else</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>(ALDI)<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yer<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElTip<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> cpuElTip<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> cpuElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">for</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> g <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span>g<span style="color: #000080;">&lt;=</span><span style="color: #0000dd;">54</span><span style="color: #008080;">;</span>g<span style="color: #000040;">++</span><span style="color: #008000;">&#41;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>g<span style="color: #000080;">&lt;=</span>yer<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kagitCpu<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; puan <span style="color: #000080;">=</span> puanx<span style="color: #008000;">&#40;</span>yerElTip<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span>,yerElKart<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; skorBilgisayar<span style="color: #000040;">+</span><span style="color: #000080;">=</span>puan<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElKart<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElTip<span style="color: #008000;">&#91;</span>g<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yer <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yer<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElTip<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> cpuElTip<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; yerElKart<span style="color: #008000;">&#91;</span>yer<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> cpuElKart<span style="color: #008000;">&#91;</span>atilan<span style="color: #008000;">&#93;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #666666;">// cout&lt;&lt;&quot;pc alamadi devam&quot;;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; basla <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff0000; font-style: italic;">/* &nbsp;cout&lt;&lt;&quot;\n yerdeki kartlar = &quot;;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kartlariGoster(2);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; */</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>endl<span style="color: #008080;">;</span><br />
sayacf<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>sayacf<span style="color: #000080;">==</span>9<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; eldonus<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>eldonus <span style="color: #000080;">==</span> 7<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">break</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">goto</span> oyun<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Kartlar bitti... Sayim yapiliyor....&quot;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kagitKisi <span style="color: #000080;">&gt;</span> kagitCpu<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;skorKisi<span style="color: #000040;">+</span><span style="color: #000080;">=</span><span style="color: #0000dd;">3</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kagitKisi <span style="color: #000080;">&lt;</span> kagitCpu<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; skorBilgisayar<span style="color: #000040;">+</span><span style="color: #000080;">=</span><span style="color: #0000dd;">3</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">else</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #666666;">// kagit sayisi esit bir sey yapmiyoruz.</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Bilgisayar : &quot;</span><span style="color: #000080;">&lt;&lt;</span>skorBilgisayar<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;, &quot;</span><span style="color: #000080;">&lt;&lt;</span>ad<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; : &quot;</span><span style="color: #000080;">&lt;&lt;</span>skorKisi<span style="color: #008080;">;</span><br />
skorBilgisayarToplam <span style="color: #000040;">+</span><span style="color: #000080;">=</span> skorBilgisayar<span style="color: #008080;">;</span><br />
skorKisiToplam <span style="color: #000040;">+</span><span style="color: #000080;">=</span> skorKisi<span style="color: #008080;">;</span><br />
<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>endl<span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">int</span> giris<span style="color: #008080;">;</span><br />
<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Devam etmek istiyor musunuz? (Devam : 1 / Bitir : 2)&quot;</span><span style="color: #008080;">;</span><br />
<span style="color: #0000dd;">cin</span><span style="color: #000080;">&gt;&gt;</span>giris<span style="color: #008080;">;</span><br />
<br />
<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>giris <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">goto</span> oyunbaslangic<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #666666;">/////</span><br />
<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>Toplam; Bilgisayar : &quot;</span><span style="color: #000080;">&lt;&lt;</span>skorBilgisayarToplam<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;, &quot;</span><span style="color: #000080;">&lt;&lt;</span>ad<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; : &quot;</span><span style="color: #000080;">&lt;&lt;</span>skorKisiToplam<span style="color: #008080;">;</span><br />
<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>endl<span style="color: #008080;">;</span><br />
<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span> skorBilgisayarToplam <span style="color: #000080;">&gt;</span> skorKisiToplam<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Bilgisayar Kazandi!&quot;</span><span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span> skorBilgisayarToplam <span style="color: #000080;">&lt;</span> skorKisiToplam <span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>ad<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; Tebrikler Kazandiniz!&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Berabere kaldiniz&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>endl<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">system</span><span style="color: #008000;">&#40;</span><span style="color: #FF0000;">&quot;PAUSE&quot;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #0000ff;">return</span> <span style="color: #0000ff;">EXIT_SUCCESS</span><span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">int</span> puanx<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> tip,<span style="color: #0000ff;">int</span> kart<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> puanTemp <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kart <span style="color: #000080;">==</span> 1 <span style="color: #000040;">||</span> kart <span style="color: #000080;">==</span> <span style="color: #0000dd;">11</span><span style="color: #008000;">&#41;</span><span style="color: #666666;">// as ve vale ise 1 puan</span><br />
&nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;puanTemp <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>tip <span style="color: #000080;">==</span> 1 <span style="color: #000040;">&amp;&amp;</span> kart <span style="color: #000080;">==</span> 10<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; puanTemp <span style="color: #000080;">=</span> <span style="color: #0000dd;">3</span><span style="color: #008080;">;</span> <span style="color: #666666;">// tip =1 yani karo ve 10 luysa 3 puan </span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>tip <span style="color: #000080;">==</span> <span style="color: #0000dd;">3</span> <span style="color: #000040;">&amp;&amp;</span> kart <span style="color: #000080;">==</span><span style="color: #0000dd;">2</span><span style="color: #008000;">&#41;</span><span style="color: #666666;">// sinek 2 ise 2 puan</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;puanTemp <span style="color: #000080;">=</span> <span style="color: #0000dd;">2</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">return</span> puanTemp<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">void</span> kartx<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> id<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">switch</span><span style="color: #008000;">&#40;</span>id<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">case</span> 1<span style="color: #008080;">:</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;As&quot;</span><span style="color: #008080;">;</span> <span style="color: #0000ff;">break</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">case</span> 11<span style="color: #008080;">:</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Vale&quot;</span><span style="color: #008080;">;</span> <span style="color: #0000ff;">break</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">case</span> 12<span style="color: #008080;">:</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Kiz&quot;</span><span style="color: #008080;">;</span> <span style="color: #0000ff;">break</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">case</span> 13<span style="color: #008080;">:</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Papaz&quot;</span><span style="color: #008080;">;</span> <span style="color: #0000ff;">break</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">default</span><span style="color: #008080;">:</span> <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span>id<span style="color: #008080;">;</span> <span style="color: #0000ff;">break</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span> <br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">void</span> tipx<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> id<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp;<br />
<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>id <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Karo&quot;</span><span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>id <span style="color: #000080;">==</span> 2<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; <br />
<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Maca&quot;</span><span style="color: #008080;">;</span> &nbsp; &nbsp;<br />
<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>id <span style="color: #000080;">==</span>3<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Sinek&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>id <span style="color: #000080;">==</span> 4<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;Kupa&quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
<br />
<br />
<span style="color: #008000;">&#125;</span><br />
<br />
<span style="color: #0000ff;">void</span> kartlariGoster<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> kim<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp;<br />
&nbsp; &nbsp;<span style="color: #0000ff;">for</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> k <span style="color: #000080;">=</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span> k<span style="color: #000080;">&lt;=</span><span style="color: #0000dd;">4</span><span style="color: #008080;">;</span>k<span style="color: #000040;">++</span><span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 0<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; (&quot;</span><span style="color: #000080;">&lt;&lt;</span>k<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;) &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; tipx<span style="color: #008000;">&#40;</span>cpuElTip<span style="color: #008000;">&#91;</span>k<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kartx<span style="color: #008000;">&#40;</span>cpuElKart<span style="color: #008000;">&#91;</span>k<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; (&quot;</span><span style="color: #000080;">&lt;&lt;</span>k<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;) &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; tipx<span style="color: #008000;">&#40;</span>kisiElTip<span style="color: #008000;">&#91;</span>k<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kartx<span style="color: #008000;">&#40;</span>kisiElKart<span style="color: #008000;">&#91;</span>k<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span>2<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; (&quot;</span><span style="color: #000080;">&lt;&lt;</span>k<span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;) &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; tipx<span style="color: #008000;">&#40;</span>yerElTip<span style="color: #008000;">&#91;</span>k<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot; - &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kartx<span style="color: #008000;">&#40;</span>yerElKart<span style="color: #008000;">&#91;</span>k<span style="color: #008000;">&#93;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>k<span style="color: #000080;">&lt;</span>4<span style="color: #008000;">&#41;</span> &nbsp; &nbsp; &nbsp; <span style="color: #0000dd;">cout</span><span style="color: #000080;">&lt;&lt;</span><span style="color: #FF0000;">&quot;, &quot;</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
<span style="color: #008000;">&#125;</span> &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
<span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">int</span> karistir<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> limit<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> sayi <span style="color: #000080;">=</span> <span style="color: #008000;">&#40;</span><span style="color: #0000dd;">rand</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span> <span style="color: #000040;">%</span> limit <span style="color: #008000;">&#41;</span> <span style="color: #000040;">+</span> <span style="color: #0000dd;">1</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">return</span> sayi<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
<span style="color: #0000ff;">int</span> kartVer<span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> kim<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">int</span> el <span style="color: #000080;">=</span> 0,sayisi <span style="color: #000080;">=</span> 1,kart<span style="color: #000080;">=</span>0,tip<span style="color: #000080;">=</span>0,cikmismi<span style="color: #000080;">=</span><span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">for</span><span style="color: #008000;">&#40;</span><span style="color: #0000ff;">int</span> h<span style="color: #000080;">=</span><span style="color: #0000dd;">1</span><span style="color: #008080;">;</span>h<span style="color: #000080;">&lt;=</span><span style="color: #0000dd;">4</span><span style="color: #008080;">;</span>h<span style="color: #000040;">++</span><span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 0 <span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;atilanlarCpu<span style="color: #008000;">&#91;</span>h<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;atilanlarKisi<span style="color: #008000;">&#91;</span>h<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp;<span style="color: #0000ff;">while</span><span style="color: #008000;">&#40;</span>1<span style="color: #008000;">&#41;</span><br />
&nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; kart <span style="color: #000080;">=</span> karistir<span style="color: #008000;">&#40;</span>13<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span> &nbsp; &nbsp; <br />
&nbsp; tip <span style="color: #000080;">=</span> karistir<span style="color: #008000;">&#40;</span>4<span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span><br />
&nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>tip <span style="color: #000080;">==</span> 1 <span style="color: #008000;">&#41;</span><br />
&nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>karo<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cikmismi <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 0<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> <span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kisiElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kisiElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 2<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span> &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;karo<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;sayisi<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> <span style="color: #008000;">&#40;</span>tip <span style="color: #000080;">==</span> 2<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
<br />
&nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>maca<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cikmismi <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 0<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> <span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kisiElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kisiElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 2<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span> &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;maca<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;sayisi<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp;<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>tip <span style="color: #000080;">==</span> 3<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>sinek<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cikmismi <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 0<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> <span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kisiElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kisiElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 2<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span> &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;sinek<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;sayisi<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>tip <span style="color: #000080;">==</span> 4<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kupa<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cikmismi <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 0<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;cpuElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> <span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 1<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; kisiElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kisiElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span> <br />
<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>kim <span style="color: #000080;">==</span> 2<span style="color: #008000;">&#41;</span><br />
<span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElKart<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> kart<span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yerElTip<span style="color: #008000;">&#91;</span>sayisi<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> tip<span style="color: #008080;">;</span> &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;kupa<span style="color: #008000;">&#91;</span>kart<span style="color: #008000;">&#93;</span> <span style="color: #000080;">=</span> <span style="color: #0000dd;">0</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;sayisi<span style="color: #000040;">++</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #008000;">&#125;</span><br />
<br />
<br />
&nbsp; <span style="color: #0000ff;">if</span><span style="color: #008000;">&#40;</span>sayisi <span style="color: #000080;">==</span> 5<span style="color: #008000;">&#41;</span><br />
&nbsp; <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">break</span><span style="color: #008080;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;">&#125;</span><br />
<span style="color: #008000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp;<br />
<span style="color: #008000;">&#125;</span></div></td></tr></tbody></table></div>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/c-ile-consolda-pisti-oyunu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>c# ile picturebox , global değişken ve random örneklendirmesi</title>
		<link>http://www.saho.in/c-ile-picturebox-global-degisken-ve-random-orneklendirmesi/</link>
		<comments>http://www.saho.in/c-ile-picturebox-global-degisken-ve-random-orneklendirmesi/#comments</comments>
		<pubDate>Wed, 17 Mar 2010 19:53:19 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[c picturebox]]></category>
		<category><![CDATA[c sharp]]></category>
		<category><![CDATA[c timer]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[c# öğren]]></category>
		<category><![CDATA[örnek]]></category>
		<category><![CDATA[uygulama]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=764</guid>
		<description><![CDATA[c# ile global değişkenlere örnek ( puan )
random sayı üretme
picturebox nesnesini ve timer1 kullanımı için giriş seviyesinde örnekler

Ekteki resimdeki gibi toolbox tan label,button,picturebox ve timer nesnelerini formumuza ekliyoruz.
label in text özelliğine puan yazıyoruz button.text ine başlat yazıyoruz
timer1.interval özelliğini biraz düşürebilirsiniz.
picturebox un image özelliğine kendi belirlediğimiz rastgele bir resmi ekliyoruz daha sonra aşağıdaki kaynak kodları yazıyoruz [...]]]></description>
			<content:encoded><![CDATA[<p>c# ile global değişkenlere örnek ( puan )</p>
<p>random sayı üretme</p>
<p>picturebox nesnesini ve timer1 kullanımı için giriş seviyesinde örnekler<a href="http://www.saho.in/wp-content/uploads/2010/03/c_sharp_uygulama.jpg"><img class="aligncenter size-medium wp-image-765" title="c_sharp_uygulama" src="http://www.saho.in/wp-content/uploads/2010/03/c_sharp_uygulama-300x178.jpg" alt="c_sharp_uygulama" width="300" height="178" /></a></p>
<p style="text-align: center;">
<p>Ekteki resimdeki gibi toolbox tan label,button,picturebox ve timer nesnelerini formumuza ekliyoruz.</p>
<p>label in text özelliğine puan yazıyoruz button.text ine başlat yazıyoruz</p>
<p>timer1.interval özelliğini biraz düşürebilirsiniz.</p>
<p>picturebox un image özelliğine kendi belirlediğimiz rastgele bir resmi ekliyoruz daha sonra aşağıdaki kaynak kodları yazıyoruz ve çalıştırıyoruz.</p>
<p>sorularınızı yorum kısmından yazabilirsiniz : )<span id="more-764"></span></p>
<div class="codecolorer-container csharp default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br />48<br />49<br />50<br />51<br />52<br />53<br />54<br />55<br />56<br />57<br />58<br />59<br />60<br />61<br />62<br /></div></td><td><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0600FF;">using</span> <span style="color: #008080;">System</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Collections.Generic</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.ComponentModel</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Data</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Drawing</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Linq</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Text</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">using</span> <span style="color: #008080;">System.Windows.Forms</span><span style="color: #008000;">;</span><br />
<br />
<span style="color: #0600FF;">namespace</span> WindowsFormsApplication1<br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0600FF;">public</span> <span style="color: #0600FF;">partial</span> <span style="color: #FF0000;">class</span> Form1 <span style="color: #008000;">:</span> Form<br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0600FF;">public</span> Form1<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
InitializeComponent<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #0600FF;">private</span> <span style="color: #0600FF;">void</span> Form1_Load<span style="color: #000000;">&#40;</span><span style="color: #FF0000;">object</span> sender, EventArgs e<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #0600FF;">private</span> <span style="color: #0600FF;">void</span> timer1_Tick<span style="color: #000000;">&#40;</span><span style="color: #FF0000;">object</span> sender, EventArgs e<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
pictureBox1.<span style="color: #0000FF;">Visible</span> <span style="color: #008000;">=</span> pictureBox1.<span style="color: #0000FF;">Visible</span> <span style="color: #008000;">==</span> <span style="color: #0600FF;">true</span> <span style="color: #008000;">?</span> <span style="color: #0600FF;">false</span> <span style="color: #008000;">:</span> true<span style="color: #008000;">;</span><br />
Random r <span style="color: #008000;">=</span> <a href="http://www.google.com/search?q=new+msdn.microsoft.com"><span style="color: #008000;">new</span></a> Random<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #FF0000;">int</span> x <span style="color: #008000;">=</span> r.<span style="color: #0000FF;">Next</span><span style="color: #000000;">&#40;</span>1, ClientSize.<span style="color: #0000FF;">Width</span> <span style="color: #008000;">-</span> pictureBox1.<span style="color: #0000FF;">Width</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #FF0000;">int</span> y <span style="color: #008000;">=</span> r.<span style="color: #0000FF;">Next</span><span style="color: #000000;">&#40;</span>1, ClientSize.<span style="color: #0000FF;">Height</span> <span style="color: #008000;">-</span> pictureBox1.<span style="color: #0000FF;">Height</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #008080; font-style: italic;">// &nbsp; &nbsp;if (x &amp;lt; 0) MessageBox.Show(x.ToString());</span><br />
pictureBox1.<span style="color: #0000FF;">Top</span> <span style="color: #008000;">=</span> x<span style="color: #008000;">;</span><br />
pictureBox1.<span style="color: #0000FF;">Left</span> <span style="color: #008000;">=</span> y<span style="color: #008000;">;</span><br />
<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #0600FF;">private</span> <span style="color: #0600FF;">void</span> button1_Click<span style="color: #000000;">&#40;</span><span style="color: #FF0000;">object</span> sender, EventArgs e<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0600FF;">if</span> <span style="color: #000000;">&#40;</span>timer1.<span style="color: #0000FF;">Enabled</span> <span style="color: #008000;">==</span> <span style="color: #0600FF;">true</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
timer1.<span style="color: #0000FF;">Enabled</span> <span style="color: #008000;">=</span> false<span style="color: #008000;">;</span><br />
button1.<span style="color: #0000FF;">Text</span> <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;Başla&quot;</span><span style="color: #008000;">;</span><br />
DialogResult yanit<span style="color: #008000;">;</span><br />
yanit <span style="color: #008000;">=</span> MessageBox.<span style="color: #0000FF;">Show</span><span style="color: #000000;">&#40;</span><span style="color: #666666;">&quot;Oyunu da bitirmek istermisiniz ? &quot;</span>, <span style="color: #666666;">&quot;El-Cevap&quot;</span>, MessageBoxButtons.<span style="color: #0000FF;">YesNo</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">if</span> <span style="color: #000000;">&#40;</span>yanit <span style="color: #008000;">==</span> DialogResult.<span style="color: #0000FF;">Yes</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0600FF;">this</span>.<span style="color: #0000FF;">Close</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0600FF;">else</span><br />
<span style="color: #000000;">&#123;</span><br />
timer1.<span style="color: #0000FF;">Enabled</span> <span style="color: #008000;">=</span> true<span style="color: #008000;">;</span><br />
button1.<span style="color: #0000FF;">Text</span> <span style="color: #008000;">=</span> <span style="color: #666666;">&quot;Bitir&quot;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #FF0000;">int</span> puan <span style="color: #008000;">=</span> <span style="color: #FF0000;">0</span><span style="color: #008000;">;</span><br />
<span style="color: #0600FF;">private</span> <span style="color: #0600FF;">void</span> pictureBox1_Click<span style="color: #000000;">&#40;</span><span style="color: #FF0000;">object</span> sender, EventArgs e<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
puan <span style="color: #008000;">+=</span> <span style="color: #FF0000;">50</span><span style="color: #008000;">;</span><br />
label1.<span style="color: #0000FF;">Text</span> <span style="color: #008000;">=</span> puan.<span style="color: #0000FF;">ToString</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #008000;">;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/c-ile-picturebox-global-degisken-ve-random-orneklendirmesi/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>c# ve xna ile 2 boyutlu oyun / fiziksel olay testleri</title>
		<link>http://www.saho.in/c-ve-xna-ile-2-boyutlu-oyun-fiziksel-olay-testleri/</link>
		<comments>http://www.saho.in/c-ve-xna-ile-2-boyutlu-oyun-fiziksel-olay-testleri/#comments</comments>
		<pubDate>Wed, 17 Mar 2010 19:32:07 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[2 boyutlu]]></category>
		<category><![CDATA[2d]]></category>
		<category><![CDATA[c#]]></category>
		<category><![CDATA[fiziksel olaylar]]></category>
		<category><![CDATA[oyun]]></category>
		<category><![CDATA[proje]]></category>
		<category><![CDATA[saü]]></category>
		<category><![CDATA[tef]]></category>
		<category><![CDATA[xna]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=759</guid>
		<description><![CDATA[c# ın xna kütüphanesi ile 2 boyutlu oyun vari bir uygulama ile fiziksel olay testlerini yapan bir uygulama hazırlıyorum proje nin son günü nisan sonu gibi , nisan sonu proje teslim tarihi dolunca projeyi internette yayınlayacağım, güzel oluyor gibi hız , sürtünme, yer çekimi vs. ile ilgili deneyler hesaplamaları 2 boyutlu çizimler ile yapıyor.
İnternette XNA [...]]]></description>
			<content:encoded><![CDATA[<p>c# ın xna kütüphanesi ile 2 boyutlu oyun vari bir uygulama ile fiziksel olay testlerini yapan bir uygulama hazırlıyorum proje nin son günü nisan sonu gibi , nisan sonu proje teslim tarihi dolunca projeyi internette yayınlayacağım, güzel oluyor gibi hız , sürtünme, yer çekimi vs. ile ilgili deneyler hesaplamaları 2 boyutlu çizimler ile yapıyor.<br />
İnternette XNA ile ilgili genel itibariyle bir çok makale/yazı okudum ama özellikle ahmet kakıcı (bu boyutu seçmemde teşvikçi) ve mehmet aydın ünlü ye teşekkür ederim <img src='http://www.saho.in/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>eğer bu boyuta geçmemiş olsam picturebox lar ın background özelliğine satranç tahtası gibi bir beyaz bir siyah arka fonlar koyup , image özelliğine satranç taşlarını yerleştirmek ve ilk tıklandığı anda  o adresin konumunu alıp 2. tıklandığı anda tıklandığı picturebox un x-y si ile karşılaştırılıp oraya gidip gitmemesi uygun mu değil mi ? o gittiği koordinat dolu mu boşmu gibi denetimler yaptırıp taşı oraya koymak sanırım bana fazla bir şey katmayacaktı yeni bir heyacan daha iyi gibi :p</p>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/c-ve-xna-ile-2-boyutlu-oyun-fiziksel-olay-testleri/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>java ile 3 e 3 Matris</title>
		<link>http://www.saho.in/java-ile-3-e-3-matris/</link>
		<comments>http://www.saho.in/java-ile-3-e-3-matris/#comments</comments>
		<pubDate>Wed, 17 Mar 2010 19:00:33 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[ahmet zengin]]></category>
		<category><![CDATA[java ile uygulama]]></category>
		<category><![CDATA[matris]]></category>
		<category><![CDATA[nesne yönelimli programlama]]></category>
		<category><![CDATA[sakarya üniversitesi]]></category>
		<category><![CDATA[teknik eğitim fakültesi]]></category>

		<guid isPermaLink="false">http://www.saho.in/?p=756</guid>
		<description><![CDATA[bu yazımda , sakarya üniversitesi &#8211; teknik eğitim fakültesi ; nesne yönelimli programlama ( java ) ödevi için
ahmet zengin hocamınız verdiği ödevin kaynak kodları olacak.
Ödevin içeriği : java ile 3-3 lük bir matris in içerisinde 1-9 arası rakamları yalnızca bir defa kullanılacak ve yatay dikey ve çaprazlamasına toplamları 15 i verecek şekilde tasarlayan uygulama : [...]]]></description>
			<content:encoded><![CDATA[<p>bu yazımda , sakarya üniversitesi &#8211; teknik eğitim fakültesi ; nesne yönelimli programlama ( java ) ödevi için<br />
ahmet zengin hocamınız verdiği ödevin kaynak kodları olacak.<br />
Ödevin içeriği : java ile 3-3 lük bir matris in içerisinde 1-9 arası rakamları yalnızca bir defa kullanılacak ve yatay dikey ve çaprazlamasına toplamları 15 i verecek şekilde tasarlayan uygulama : )<br />
<strong> Kaynak kodlar aşağıda ben kısaca mantığını anlatayım.<a href="http://www.saho.in/wp-content/uploads/2010/03/java-matris.jpg"><img class="aligncenter size-medium  wp-image-772" title="java-matris" src="http://www.saho.in/wp-content/uploads/2010/03/java-matris-300x187.jpg" alt="java-matris" width="300" height="187" /></a></strong></p>
<p><span id="more-756"></span>ihtiyacımız olan değişkenler</p>
<p>matris elemanları için bir array random sayı için bir int , temp için bir int , ekleme ve devam etme durumları için boolean değişkenler,kod içerisinde lazım olan başka şeylerde olabiliyor döngü değişkenleri vs.</p>
<p>bir while döngüsü ve bu döngü a arrayının eleman sayısı 9 dan küçük olduğu sürece çalışma koşulunda yazılıyor.</p>
<p>daha sonra rastgele bir sayı seçtiriyoruz 3-3 matris olduğundna ilk 2 eleman ı random seçebilir 1-9 aralığında</p>
<p>bu seçim sırasında da sayı daha önce seçilenlerde varmı yok mu diye denetim yaptırmalıyız ve bu deneme bir do -while döngüsü içerisinde olmalı ve eğer daha önce seçilmemişse döngünün çalışması durdurulmalı</p>
<p>neden while değilde ? do while diyecek olursa çünki 1 defa da da o elemanı bulabiliriz 10 defa da da ama 1 defa kesinlikle çalışmasını istiyoruz o döngünün bu sebeple do while kullanmamız daha makûl&#8230;</p>
<p>ilk 2 sayıyı bir birinden benzersiz olarak seçtirdik</p>
<p>geldik 3. sayıyı seçmeye biz kendimiz o satırın ilk 2 elemanın değerinin toplamını 15 ten çıkararak buluyoruz,</p>
<p>3. sayı olduğunuda kayitsayisi değişkenimiz mevcut her seferinde +1 olarak artan ,</p>
<p>kayitsayisi % 3 == 2 olduğunda yani kayitsayisinin 3 e göre modu 2 olduğunda biz matrisin o satırının son elemanına geldiğimizi anlıyoruz .</p>
<p>daha sonra burada bir denetim yaptırıyoruz 3. sayı 0 ve  dan küçük veya 9 dan büyük olamaz .</p>
<p>eğer öyle ise o satırdaki 2 elemanıda siliyoruz kayitsayısında 2 azaltıyoruz.</p>
<p>eğer 15 ten çıkarıp o satırın son elemanı olacak matris daha önce random olarak tutulmuş ise o tutulan sayıya kadar tüm dizinin içeriğini siliyoruz ve kayıt sayisini ne kadar sildiysek o kadar azaltıyoruz.</p>
<p>bu şekilde gidiyor geliyoruz dikeylemesine 15 i bulmaya , dikine 15 içinde</p>
<p>kayitsayisi &gt; 5 mi denetimi yapıyoruz , eğer 5 ten büyükse son satırdaki elemanları seçiyoruz demektir.</p>
<p>satırdaki son sayıları seçtiğimizden o sayı 0&lt;= mi veya 9 &gt; veya daha önce matrise eklenmiş mi bu denetimleri yaptırıyoruz şartlardan herhangi birisi  sağlanıyorsa artık geriye dönmek daha zor tek tek arrayları silip toplattırmak yerine ben while döngüsünden önce bir label-etiket tanımladım sec: adında</p>
<p>eğer bu şartlar sağlanıyorsa kayitsayisini 0 lıyor a arrayının içeriğini boşaltıyor ve sec: label indan program tekrar başlıyor bazen 5 bazen 50 denemede istenen şartı sağlıyor.</p>
<p>Daha optimize daha kısa kodlar yazılabilir miydi tabi ki 20 yoldan da yapabilirsiniz bu uygulamayı ve denetimleri farklı metotlara gönderip daha az kod ile de işlemlerinizi yapabilirsiniz zaten debug satırlarını vs. silincede uygulama kısalacaktır, elimden geldiğince anlatmaya çalıştım soru ve sorunlarınızı olursa yazabilirsiniz.</p>
<div class="codecolorer-container java default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;height:300px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br />48<br />49<br />50<br />51<br />52<br />53<br />54<br />55<br />56<br />57<br />58<br />59<br />60<br />61<br />62<br />63<br />64<br />65<br />66<br />67<br />68<br />69<br />70<br />71<br />72<br />73<br />74<br />75<br />76<br />77<br />78<br />79<br />80<br />81<br />82<br />83<br />84<br />85<br />86<br />87<br />88<br />89<br />90<br />91<br />92<br />93<br />94<br />95<br />96<br />97<br />98<br />99<br />100<br />101<br />102<br />103<br />104<br />105<br />106<br />107<br />108<br />109<br />110<br />111<br />112<br />113<br />114<br />115<br />116<br />117<br />118<br />119<br />120<br />121<br />122<br />123<br />124<br />125<br />126<br />127<br />128<br />129<br />130<br />131<br />132<br />133<br />134<br />135<br />136<br />137<br />138<br />139<br />140<br />141<br />142<br />143<br /></div></td><td><div class="java codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
*<br />
*/</span><br />
<span style="color: #666666; font-style: italic;">//package tahta;&lt;/code&gt;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">import</span> <span style="color: #006699;">java.util.ArrayList</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
* @author Saho<br />
*<br />
*/</span><br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> Index <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000066; font-weight: bold;">int</span> max <span style="color: #339933;">=</span> <span style="color: #cc66cc;">15</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000066; font-weight: bold;">boolean</span> debug <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
*<br />
*/</span><br />
<span style="color: #000000; font-weight: bold;">public</span> Index<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #666666; font-style: italic;">// TODO Auto-generated constructor stub</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000066; font-weight: bold;">boolean</span> DenetimOrta<span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aarraylist+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">ArrayList</span></a> a<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> Kombinasyon1 <span style="color: #339933;">=</span> 0, Kombinasyon2 <span style="color: #339933;">=</span> 0, max <span style="color: #339933;">=</span> Index.<span style="color: #006633;">max</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">boolean</span> debug <span style="color: #339933;">=</span> Index.<span style="color: #006633;">debug</span><span style="color: #339933;">;</span><br />
Kombinasyon1 <span style="color: #339933;">=</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>0<span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>4<span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>8<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
Kombinasyon2 <span style="color: #339933;">=</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>2<span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>4<span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>6<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>debug <span style="color: #339933;">==</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>Kombinasyon1<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>Kombinasyon2<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>Kombinasyon1 <span style="color: #339933;">==</span> max <span style="color: #339933;">&amp;</span>amp<span style="color: #339933;">;&amp;</span>amp<span style="color: #339933;">;</span> Kombinasyon2 <span style="color: #339933;">==</span> max<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000066; font-weight: bold;">boolean</span> Denetim<span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aarraylist+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">ArrayList</span></a> a, <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Ainteger+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Integer</span></a> e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">boolean</span> varmis <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> i <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span> i <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> a.<span style="color: #006633;">size</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> i<span style="color: #339933;">++</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>i<span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> e<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
varmis <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">return</span> varmis<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
* @param args<br />
*/</span><br />
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">static</span> <span style="color: #000066; font-weight: bold;">void</span> main<span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Astring+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">String</span></a><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> args<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #666666; font-style: italic;">// TODO Auto-generated method stub</span><br />
<span style="color: #000066; font-weight: bold;">int</span> deneme <span style="color: #339933;">=</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> max <span style="color: #339933;">=</span> Index.<span style="color: #006633;">max</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">boolean</span> debug <span style="color: #339933;">=</span> Index.<span style="color: #006633;">debug</span><span style="color: #339933;">;</span><br />
<span style="color: #666666; font-style: italic;">// long MaxDeneme = 1000000000;// 15000;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> temp <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aarraylist+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">ArrayList</span></a> a <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aarraylist+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">ArrayList</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> Ekle <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> r1 <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> KayitSayisi <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
sec<span style="color: #339933;">:</span> <span style="color: #000000; font-weight: bold;">while</span> <span style="color: #009900;">&#40;</span>a.<span style="color: #006633;">size</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> 9<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000066; font-weight: bold;">boolean</span> devam <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #339933;">;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000066; font-weight: bold;">boolean</span> ekleme <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #339933;">;</span> &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>KayitSayisi <span style="color: #339933;">%</span> 3 <span style="color: #339933;">==</span> 2<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000; font-weight: bold;">do</span> <span style="color: #009900;">&#123;</span> &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; temp <span style="color: #339933;">=</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>KayitSayisi <span style="color: #339933;">-</span> 2<span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>KayitSayisi <span style="color: #339933;">-</span> 1<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Ekle <span style="color: #339933;">=</span> max <span style="color: #339933;">-</span> temp<span style="color: #339933;">;</span> &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>Ekle <span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;</span> 9 <span style="color: #339933;">||</span> Ekle <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> 1<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
a.<span style="color: #006633;">remove</span><span style="color: #009900;">&#40;</span>KayitSayisi <span style="color: #339933;">-</span> 1<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
a.<span style="color: #006633;">remove</span><span style="color: #009900;">&#40;</span>KayitSayisi <span style="color: #339933;">-</span> 2<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
KayitSayisi <span style="color: #339933;">=</span> KayitSayisi <span style="color: #339933;">-</span> <span style="color: #cc66cc;">2</span><span style="color: #339933;">;</span><br />
devam <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
ekleme <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>debug <span style="color: #339933;">==</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>Ekle<br />
<span style="color: #339933;">+</span> <span style="color: #0000ff;">&quot; 9 dan büyük 1 den küçük &quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">else</span> <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>Denetim<span style="color: #009900;">&#40;</span>a, Ekle<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> silici <span style="color: #339933;">=</span> KayitSayisi <span style="color: #339933;">-</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span><br />
<span style="color: #000066; font-weight: bold;">int</span> dus <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">while</span> <span style="color: #009900;">&#40;</span>Denetim<span style="color: #009900;">&#40;</span>a, Ekle<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>silici <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;=</span> 0<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000; font-weight: bold;">break</span><span style="color: #339933;">;</span> &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;">&#125;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; a.<span style="color: #006633;">remove</span><span style="color: #009900;">&#40;</span>silici <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// burada -1 de problem çıkıyor &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; silici--; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; dus++; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; KayitSayisi = KayitSayisi - dus; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; devam = false; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ekleme = false; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (debug == true) &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; System.out.println(Ekle + &quot; kayıtlarda var &quot;); &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } else { &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; devam = false; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (debug == true) &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; System.out.println(Ekle &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; + &quot; ne 9 dan büyük ne kayıtta var &quot;); &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ekleme = true; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; deneme++; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; } while (devam); &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; } else { &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if (KayitSayisi &amp;gt; 5) {</span><br />
temp <span style="color: #339933;">=</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>KayitSayisi <span style="color: #339933;">-</span> 6<span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>KayitSayisi <span style="color: #339933;">-</span> 3<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
Ekle <span style="color: #339933;">=</span> max <span style="color: #339933;">-</span> temp<span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>Ekle <span style="color: #339933;">&amp;</span>gt<span style="color: #339933;">;</span> 9 <span style="color: #339933;">||</span> Ekle <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> 1 <span style="color: #339933;">||</span> Denetim<span style="color: #009900;">&#40;</span>a, Ekle<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
temp <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
a <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aarraylist+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">ArrayList</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
Ekle <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
r1 <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
KayitSayisi <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
ekleme <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">continue</span> sec<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">while</span> <span style="color: #009900;">&#40;</span>devam<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
r1 <span style="color: #339933;">=</span> 1 <span style="color: #339933;">+</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#40;</span><a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Amath+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">Math</span></a>.<span style="color: #006633;">random</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">*</span> 9<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
devam <span style="color: #339933;">=</span> Denetim<span style="color: #009900;">&#40;</span>a, r1<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
Ekle <span style="color: #339933;">=</span> r1<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>debug <span style="color: #339933;">==</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>Ekle <span style="color: #339933;">+</span> <span style="color: #0000ff;">&quot; ilk 2 kolon &quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>ekleme <span style="color: #339933;">==</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
a.<span style="color: #006633;">add</span><span style="color: #009900;">&#40;</span>Ekle<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
KayitSayisi<span style="color: #339933;">++;</span><br />
<span style="color: #009900;">&#125;</span><br />
deneme<span style="color: #339933;">++;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>a.<span style="color: #006633;">size</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">==</span> 9 <span style="color: #339933;">&amp;</span>amp<span style="color: #339933;">;&amp;</span>amp<span style="color: #339933;">;</span> <span style="color: #339933;">!</span>DenetimOrta<span style="color: #009900;">&#40;</span>a<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>debug <span style="color: #339933;">==</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;------&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> j <span style="color: #339933;">=</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span> j <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;=</span> a.<span style="color: #006633;">size</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> j<span style="color: #339933;">++</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>j <span style="color: #339933;">%</span> 3 <span style="color: #339933;">==</span> 0<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>j <span style="color: #339933;">-</span> 1<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">print</span><span style="color: #009900;">&#40;</span>a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>j <span style="color: #339933;">-</span> <span style="color: #cc66cc;">1</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> <span style="color: #0000ff;">&quot; &quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
temp <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
a <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> <a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Aarraylist+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">ArrayList</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
Ekle <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
r1 <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
KayitSayisi <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span><br />
ekleme <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">false</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">continue</span> sec<span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #666666; font-style: italic;">// if (deneme &amp;gt;= MaxDeneme)</span><br />
<span style="color: #666666; font-style: italic;">// break;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>debug <span style="color: #339933;">==</span> <span style="color: #000066; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;------&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000000; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">int</span> j <span style="color: #339933;">=</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">;</span> j <span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;=</span> a.<span style="color: #006633;">size</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> j<span style="color: #339933;">++</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>j <span style="color: #339933;">%</span> 3 <span style="color: #339933;">==</span> 0<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">println</span><span style="color: #009900;">&#40;</span>a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>j <span style="color: #339933;">-</span> 1<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">else</span> <span style="color: #009900;">&#123;</span><br />
<a href="http://www.google.com/search?hl=en&amp;q=allinurl%3Asystem+java.sun.com&amp;btnI=I%27m%20Feeling%20Lucky"><span style="color: #003399;">System</span></a>.<span style="color: #006633;">out</span>.<span style="color: #006633;">print</span><span style="color: #009900;">&#40;</span>a.<span style="color: #006633;">get</span><span style="color: #009900;">&#40;</span>j <span style="color: #339933;">-</span> <span style="color: #cc66cc;">1</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> <span style="color: #0000ff;">&quot; &quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
<span style="color: #008000; font-style: italic; font-weight: bold;">/**<br />
* @author Şahabettin Akca<br />
*<br />
*/</span></div></td></tr></tbody></table></div>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/java-ile-3-e-3-matris/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Mysql ile Çapraz olarak tablo güncellemesi yapma</title>
		<link>http://www.saho.in/mysql-ile-capraz-olarak-tablo-guncellemesi-yapma/</link>
		<comments>http://www.saho.in/mysql-ile-capraz-olarak-tablo-guncellemesi-yapma/#comments</comments>
		<pubDate>Sat, 27 Feb 2010 05:19:50 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[çapraz]]></category>
		<category><![CDATA[cross]]></category>
		<category><![CDATA[güncelleme]]></category>
		<category><![CDATA[set]]></category>
		<category><![CDATA[sql]]></category>
		<category><![CDATA[substr]]></category>
		<category><![CDATA[substring]]></category>
		<category><![CDATA[substring_index]]></category>
		<category><![CDATA[update]]></category>

		<guid isPermaLink="false">http://www.saho.in/mysql-ile-capraz-olarak-tablo-guncellemesi-yapma/</guid>
		<description><![CDATA[UPDATE uyeler AS s , uyelerYedek AS q
SET s.dogumTarihi = q.yas
where s.id = q.id 
gibi yaparak eski / yedek tablonuzdaki verileri yeni tablonuzdakilerle değiştirebilirsiniz
ansızın gece nin 5:30 unde uyeler tablosunun dogumTarihi kolonunun veritipini değiştiğinizde (örneğin varchar dan date ) tüm verilerin silineeğini unutmayınız yedeğiniz varsa eski kolondaki verileri alabilirsiniz 
veya substring_index(q.yas,&#8217;.',-1) as yil gibi gibi [...]]]></description>
			<content:encoded><![CDATA[<p>UPDATE uyeler AS s , uyelerYedek AS q<br />
SET s.dogumTarihi = q.yas<br />
where s.id = q.id </p>
<p>gibi yaparak eski / yedek tablonuzdaki verileri yeni tablonuzdakilerle değiştirebilirsiniz<br />
ansızın gece nin 5:30 unde uyeler tablosunun dogumTarihi kolonunun veritipini değiştiğinizde (örneğin varchar dan date ) tüm verilerin silineeğini unutmayınız yedeğiniz varsa eski kolondaki verileri alabilirsiniz <img src='http://www.saho.in/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
veya substring_index(q.yas,&#8217;.',-1) as yil gibi gibi tarihleri parse edipte aktarabilirsiniz.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&nbsp;UPDATE uyeler AS s , uyelerYedek AS q<br />
SET <br />
s.dogumTarihi = concat(<br />
SUBSTRING_INDEX( q.yas , '.', -1 ) <br />
,'-',<br />
substring_index(SUBSTRING_INDEX( q.yas , '.', 2),'.',-1)<br />
,'-',<br />
SUBSTRING_INDEX( q.yas , '.', 1 ) <br />
)<br />
<br />
WHERE s.id = q.id</div></td></tr></tbody></table></div>
]]></content:encoded>
			<wfw:commentRss>http://www.saho.in/mysql-ile-capraz-olarak-tablo-guncellemesi-yapma/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
