Sınıflar ve Nesneler (class)

Ebat: px
Şu sayfadan göstermeyi başlat:

Download "Sınıflar ve Nesneler (class)"

Transkript

1 Sınıflar ve Nesneler (class)

2 Sınıflara ve Nesnelere Giriş Nesneye yönelik programlama terminolojisinde, bir sınıf programcı tarafından tanımlanmış bir yeni tip gibidir Tıpkı doğal dillerdeki sınıf tanımı gibi: Aynı özellikleri ve fonksiyonları paylaşan elemanlar kümesidir Nesneye yönelik programlamada da tanım aynıdır Nesneye yönelik programlama dillerinde (C++gibi)nesneler bir kavrama ait herşeyi biraraya birleştirmeye yararlar (tarih, öğrenci gibi) Data(durum) (e.g. öğrenci no, not ortalaması) Fonksiyonlar (davranış) olur) (e.g. öğrenci kaydolur, öğrenci mezun

3 Nesnelere Giriş Data tiplerinden değişkenler tanımlıyoruz (int, double gibi). Benzer şekilde, sınıflardan da nesneler tanımlarız bir nesne bir sınıfın üyesidir Neden sınıflar ve nesneler? Neden nesneye dayalı programlama? Programcıya detaylarla uğraşmadan raftan hazır parçalar alıp kullanabilmesini sağlar Zaman ve çaba kazandırır Nesneler de gerçek hayattaki şeylerin programda gösterimidir. Siz de kendi sınıflarınızıtasarlayabilir ve sonra da kullanabilirsiniz, ama önce başka programcıların tanımladığı sınıfları kullanacağız Genellikle bir programcının yaptığı da budur

4 Nesneye Yönelik Programlama OO programlama olmadan Takvim yazdırma programı Bir çok yardımcı fonksiyon gerekli Artık yıl kontrolü Haftanın gününü kelimeye dönüştüren fonksiyon gerekli Data gün ay yıl Fonksiyonlar haftanın hangi günü AyĐsmi artık yıl Bu yapı kompleks mi? Kimisi için evet, kimisi için hayır...

5 Nesneye Yönelik Programlama OO versiyonu - Takvim yazdırma programı Tarih kavramı bir sınıf olarak geliştirilmiş data ve fonksiyonlar bir araya getirilmiş durumda Data (gün, ay, yıl) Fonksiyonlar Haftanın günü Ayın adı Bunu sevdiniz mi? kimisi için evet, kimisi için hayır OO yaklaşımı insan yapısına daha uygundur Đnsanın kavrayışı da nesnelere dayalıdır

6 Sınıfları nasıl kullanacağız? Bir sınıfın davranışıüye fonksiyonları(metodları) tarafından belirlenir Bu üye fonksiyonları ve ne yaptıklarını bilmek gerekir Fonksiyonun adını Parametrelerini ve parametre tiplerini Döndürdüğü tipi Fonksiyonunu Fonksiyonun nasıl çalıştığını bilmeniz gerekmez analoji: araba kullanırız ama yakıt enjeksiyonunun nasıl çalıştığını bilmemize gerek yoktur

7 Dice sınıfı Bilgisayar taklidi zar Gerçek zar değil, ama aynı fonksiyona sahip 1 ile zarın kenar sayısı arasında rastgele bir sayı atıyor Bu sınıftan oluşturacağımız zar nesneleri istediğimiz sayıda kenara sahip olabilirler Kullanıcı programcı bu sınıfa şu başlık dosyasından ulaşabilir #include "dice.h

8 Dice sınıfı Küçük bir sınıf Örnek ile görmekte fayda var Durum Kenar sayısı Zarın atılma sayısı Üye fonksiyonları Dice(int sides); // constructor verilen sides kenarlı bir zar oluşturur int Roll(); // rastgele atışı döndürür int NumSides() const; // kaç tane kenar olduğunu int NumRolls() const; // zarın kaç kez atıldığını

9 Bir sınıf nerede tanımlanır? Sınıfın tanımıveüye fonksiyon prototipleri ve bazıdiğer tanımlamalar bir header dosyası(.h dosyası) içindedir Fonksiyon prototipinde fonksiyon adı, döndürdüğütipi ve parametrelerini içerir. Fonksiyon gövdesi orada değildir. Üye fonksiyonların gövdeleri.cpp dosyası içindedir Dice örneğinde Sınıfın tanımı dice.h dosyasındadır Bu yüzden roll.cpp dosyasının başına include eklenmiştir Sınıfın uygulaması dice.cpp dosyasındadır VS projesinin parçası olmalıdır birlikte link edilirler

10 dice.h başlık dosyası Dice sınıfınıkullanabilmek için #include "dice.h" demek gerekir class Dice public: Dice(int sides); // constructor int Roll(); // return the random roll int NumSides() const; // how many sides int NumRolls() const; // # times this die rolled private: int myrollcount; // # times die rolled int mysides; // # sides on die ; Her Dice nesnesinin kendine has mysides ve myrollcount değişkenleri vardır Genellikle constructor fonksiyon tarafından ilk değerleri atanırlar

11 Dice sınıfını kullanmak constructor Dice cube(6); //altı kenarlı zar oluşturur Dice dodeca(12); // 12 kenarlı zar oluşturur cout << cube.numsides() << " kenarlı zar atılıyor " << endl; cout << cube.roll() << endl; cout << cube.roll() << endl; cout << cube.numrolls() << " kere atıldı" << endl; üye roll.cpp fonksiyonlar

12 Nasıl? Nesneleri nasıl tanımlarız? sınıf_adı nesneler_listesi_virgülle_ayrılmış; Eğer argumanlar istiyorsa constructor, onları da unutmayın. Nasıl üye fonksiyon çağırdık? nesne_adı.fonksiyon_adı(argumanlar); Bir üye fonksiyon çağrıldığı nesne üzerinde işlem yapacaktır.

13 Dice ile neler yapabiliriz, neler yapamayız Kenar sayısı belirtmeden Dice nesnesi yaratamayız Bu bir hata değil, bir tasarım kararıdır Varolan sınıfı parametresiz bir constructor ile değiştirebilirsiniz Dice d(2); // ok, madeni para gibi Dice cube; // ok değil, derlenmez Dice nesnesi ne kadar rasgeledir nasıl test edebiliriz? Bir hedef toplam elde etmek için kaç kez zar atılması gerektiğini hesaplarız Bunu defalarca tekrarlarız bir ortalama elde etmek için 6 kenarlı zar kullanarak bunu 2 ve 12 arasındaki bütün değerler için tekrarlarız testdice.cpp

14 Sınıf tanımının parçaları Public Üye fonksiyonlar Programcı sadece public bölümdekileri kullanabilir Constructors Nesneleri yaratmaya yarayan özel bir üye fonksiyon (değişkenler) Aynıisimle birden fazla constructor olabilir, ama değişik parametrelerle Private Daha ziyade sınıfın data (bilgi) kısmı burada olur Sınıfın kendi iç uygulaması için kullanılırlar Örneğin. mysides used by Roll Programcı göremez Örneğin. roll.cpp, programcı mysides ı değiştiremez

15 Dice sınıfının kullanımı #include "dice.h" int main() Dice cube(6); Dice dodeca(12); Nesneler oluşturuldu cube myrollcount 0 myrollcount 0 dodeca mysides 6 mysides 12 cout << cube.roll(); int k; for(k=0; k < 6; k++) cout << dodeca.roll(); return 0; Metodlar çağırıldı cube myrollcount mysides 1 6 myrollcount Döngüden sonra dodeca mysides 6 12

16 dice.cpp 1/2 Dice::Dice(int sides) // postcondition: all private fields initialized myrollcount = 0; mysides = sides; Constructor int Dice::NumSides() const // postcondition: return # of sides of die return mysides;

17 dice.cpp 2/2 int Dice::NumRolls() const // postcondition: return # of times die has been rolled return myrollcount; int Dice::Roll() // postcondition: number of rolls updated // random 'die' roll returned RandGen gen; // random number generator myrollcount= myrollcount + 1; // update # of rolls return gen.randint(1,mysides); // in range [1..mySides]

18 .cpp dosyası Sınıfın bütün member üye fonksiyonları bu dosyadadır Her fonksiyonun adı, parametre listesi, ve döndürdüğü tip vardır Bir üye fonksiyonun adında sınıfın adı da vardır return_type sınıf_adı:: fonksiyon_adı(parametreler) Constructor lar bir şey döndürmezler sınıf_adı:: sınıf_adı(parametreler) :: operatorü fonksiyonun sınıfını belirler Her metot sınıfın private data bölgesine dokunabilir(cağırıldığı nesnenin datasına tabii) Böylece, her metot çağrılışında, üye fonksiyon değişik nesnelerin private bilgisini kullanacaktır cube.numsides() ile dodeca.numsides(). operatorü üye fonksiyon cağrılacağı zaman kullanılır

19 RandGen Sınıfı Rastgele sayı üreten bir sınıf Projenize randgen.cpp dosyasını ekleyin ve #include "randgen.h" satırını da programınızın başına ekleyin Dört üye fonksiyonu var: int RandInt(int max = INT_MAX); [0..max) aralığında bir rastgele tamsayı üretir int RandInt(int low, int max); [low..max] aralığında bir rastgele tamsayı üretir double RandReal(); [0..1) aralığında bir rastgele reel sayı üretir double RandReal(double low, double max); [low..max] aralığında bir rastgele reel sayı üretir numberguess.cpp

20 Aşırı yükleme (Overloading) RandGen sınıfında, RandInt adında iki farklı fonksiyon var RandReal de bunun gibi aynı Aynı ismi birden fazla fonksiyon için kullanmaya overloading diyoruz. Parametre tipleri ve/veya return tipleri farklıdır. Hem üye hem serbest fonksiyonlaraşırı yüklenebilirler.

21 The class Date The class Date is accessible to client programmers #include "date.h" to get access to the class The compiler needs this information. It may also contain documentation for the programmer Link the implementation in date.cpp Add this cpp to your project The class Datemodels a calendar date: Month, day, and year make up the stateof a Dateobject Dates can be printed, compared to each other, day-of-week determined, # days in month determined, many other behaviors Behaviors are called methods or member functions

22 Constructing Date objects see usedate.cpp Date today; Date republic(10,29,1923); Date million( ); Date y2k(1,1,2000); cout << "today: " << today << endl; cout << "Republic of Turkey has been founded on: " << republic << endl; cout << "millionth day: " << million << endl; OUTPUT today: April Republic of Turkey has been founded on: October millionth day: November

23 Constructing/defining an object Date objects (as all otherobjects) are constructed when they re first defined Three ways to construct a Date default constructor, no params, initialized to today s date single long int parameter, number of days from January 1, 1 three params: month, day, year (in this order). Constructors for Date objects look like function calls constructor is special member function Different parameter lists mean different constructors Once constructed, there are many ways to manipulate a Date Increment it using ++, subtract an integerfrom it using -, print it using cout, MonthName(), DayName(), DaysIn(), See date.hfor more info on date constructors and member functions

24 Date Member Functions Date MidtermExam(4,6,2011); Construct a Date object given month, day, year MidtermExam.DayName() Returns the name of the day ( Monday or Tuesday, or...) in this particular case, returns Wednesday since April 6, 2011is a Wednesday MidtermExam.DaysIn() Returns the number of days in the particular month in our case return 30, since April 2011 has 30days in it Add, subtract, increment, decrement days from a date Date GradesDue = MidtermExam + 2; GradesDue is April 8, 2011 Let s see usedate.cpp in full and datedemo.cpp now

25 Example: Father s day (not in book) Father s day is the third Sunday of June write a function that returns the date for the father s day of a given year which is the parameter of the function In main, input two years and display father s days between those years Date fathersday(int year) // post: returns fathers day of year Date d(6,1,year); // June 1 while (d.dayname()!= "Sunday") d += 1; //d is now the first Sunday, 3rd is 14 days later return d + 14; See fathersday.cpp for full program

26 Updating a Class (not in book) Suppose you want to add more functionality to the date class need to change the header file (date.h) need to add implementation of new function(s) to date.cpp Example: a new member function to calculate and return the remaining number of daysin the object s month any ideas? do you think it is too difficult? have a look at the existing member functions and see if they are useful for you

27 Updating a Class (not in book) We can make use of DaysInmember function Prototype in Date class (add to the header file) int RemainingDays () const; Implementation int Date::RemainingDays () const return DaysIn() - myday; In a member function implementationprivate data and other member functions referred without the dot operator. They operate on the object for which the member function is called

28 Updating a Class (not in book) Example use of RemainingDays Date today; cout << "There are " << today.remainingdays() << " days left in the current month" << endl; See date_modified.h, date_modified.cppand demodatemodified.cpp When RemainingDays is called, call to DaysInis forobjecttoday since it is the object on which RemainingDaysis called myday is today s myday since it is the object on which RemainingDaysis called

29 Designing classes from scratch Chapter 7 (especially 7.1 and 7.2) a good development strategy iterative enhancement approach READ those sections, you are responsible we won t cover all, because it takes too much time and becomes boring! I will give a simpler class design example here less iterative but similar application

30 Implementing Classes Iterative Enhancement It is difficult to determine what classes are needed, how they should be implemented, which functions are required Experience is a good teacher, failure is also a good teacher Good design comes from experience, experience comes from bad design Design and implementation combine into a cyclical process: design, implement, re-visit design, reimplement, test, redesign, Grow a working program, don t do everything at the same time

31 Design and Implementation Heuristics A design methodology says that look for nouns, those are classes, and then look for verbs and scenarios, those are member functions Not every noun is a class, not every verb is a member function some functions will be free ones or will be implemented in main (these are design decisions) Concentrate on behavior (member functions) first when designing classes, then on state (private part) private data will show its necessity during the implementation of the public part

32 Example class design Quiz class simple quiz of addition questions Scenarios user is asked a number of questions computer asks random questions user enters his/her answer correct / not correct feedback and correct answer are displayed correct answers are counted There may be two classes question quiz but I will have one class which is for question and implement quiz in main Be careful! This example is similar but different than the one in book (Sections 7.1 and 7.2)

33 Question class Question behaviors (verbs). A question is created asked answered checked These are candidate member functions more? less? we will see A question is simply two random integers (to keep it simple say between 1 and 100) to be added those numbers are definitely in class private data what else? we will see

34 Question class simplemathquest.h (first draft) class Question public: Question(); // create a random question void Ask() const; // ask the question to user int GetAnswer() const; //input and return user answer bool IsCorrect(int answer) const; //check if correct private: int mynum1; // numbers used in question int mynum2; ;

35 Quiz program (main - simplequiz.cpp) Draft 1 int qnum = PromptRange("how many questions: ",1,5); int k, ans, score =0; for(k=0; k < qnum; k++) Question q; q.ask(); ans = q.getanswer(); if (q.iscorrect(ans)) cout << ans << " correct answer" << endl << endl; score++; else cout << "Sorry, not correct. Correct answer was " <<???????? << endl << endl; cout << "Score is " << score << " out of " << qnum << " = " << double(score)/qnum * 100 << "%" << endl; Something missing: a function to return the correct result

36 Question class simplemathquest.h (second draft) class Question public: Question(); // create a random question void Ask() const; // ask the question to user int GetAnswer() const; //input and return user answer bool IsCorrect(int answer) const; //check if correct int CorrectAnswer() const; //return the correct answer private: int mynum1; // numbers used in question int mynum2; ;

37 Quiz program (simplequiz.cpp) Draft 2 int qnum = PromptRange("how many questions: ",1,5); int k, ans, score =0; for(k=0; k < qnum; k++) Question q; q.ask(); ans = q.getanswer(); if (q.iscorrect(ans)) cout << ans << " correct answer" << endl << endl; score++; else cout << "Sorry, not correct. Correct answer was " << q.correctanswer() << endl << endl; cout << "Score is " << score << " out of " << qnum << " = " << double(score)/qnum * 100 << "%" << endl;

38 Question class implementation simplemathquest.cpp (draft 1) Question::Question() RandGen gen; constructor mynum1 = gen.randint(1,100); mynum2 = gen.randint(1,100); void Question::Ask() const cout << mynum1 << " + " << mynum2 << " = "; int Question::GetAnswer() const int ans; cin >> ans; return ans; Ooops! We did not access or modify the object s state. It is better not to have this function as a member function

39 Question class implementation simplemathquest.cpp(draft 1) - continued bool Question::IsCorrect(int answer) const return?????? == answer; int Question::CorrectAnswer() const return??????; Problem: Where is the correct answer stored? a new private data field would be good

40 Question class simplemathquest.h (final) class Question public: Question(); void Ask() const; // create a random question // ask the question to user int GetAnswer() const; //input and return user answer bool IsCorrect(int answer) const; //check if correct int CorrectAnswer() const; //return the correct answer private: int mynum1; // numbers used in question int mynum2; int myanswer; // store the answer ;

41 Question class implementation simplemathquest.cpp(final) Question::Question() RandGen gen; mynum1 = gen.randint(1,100); mynum2 = gen.randint(1,100); myanswer = mynum1 + mynum2; void Question::Ask() const cout << mynum1 << " + " << mynum2 << " = "; int Question::GetAnswer() const int ans; cin >> ans; return ans;

42 Question class implementation simplemathquest.cpp(final) - continued bool Question::IsCorrect(int answer) const return myanswer == answer; int Question::CorrectAnswer() const return myanswer;

43 Quiz program (simplequiz.cpp) Final int qnum = PromptRange("how many questions: ",1,5); int k, ans, score =0; for(k=0; k < qnum; k++) Question q; q.ask(); cin >> ans; if (q.iscorrect(ans)) cout << ans << " correct answer" << endl << endl; score++; else cout << "Sorry, not correct. Correct answer was " << q.correctanswer() << endl << endl; cout << "Score is " << score << " out of " << qnum << " = " << double(score)/qnum * 100 << "%" << endl;

44 Thinking further What about a generic question class not only addition, but also other arithmetic operations may need another private data memberfor the operation that is also useful to display the sign of operation in Ask may need parameter in the constructor (for question type) will do this week in recitations What about questions for which answers are strings? maybe our generic question class should have string type answersto serve not only to arithmetic questions but any type of questions see Sections 7.1 and 7.2

45 string as a class string is a class string variables are objects, they re instances of the class A class is a collection of members that have common attributes strings share some properties, but have different values A string is a sequence of characters first char is at position 0 first index is 0 last valid index (position of the last character): string s length-1 Constructors without initialization string mystr, s; with initialization string s = "Hello World"; string otherstring = s; or string otherstring(s); You may use functions and operators that return strings in initialization string s = "Hello" + "World"; //concatenation operator

46 string member functions The function length() returns the number of characters string s = "hello"; int len = s.length(); // value of len is 5 s = ""; // s is null string len = s.length(); // value of len is 0 Member functions are applied to objects using dot notation Cannot use length() without an object to apply it to Not valid int x = length(s); Not valid int x = string.length(); Valid? double y = sqrt(s.length());

47 string member functions int length() // postcondition: returns the number of characters string substr(int pos, int len) // precondition: 0 <= pos, and pos < length of the string object // postcondition: returns substring of len characters beginning at position // pos. Returns as many characters as possible if len is too large, but // causes error if pos is out of range (>= length of the string object) int find(string s) // postcondition: returns first position/index at which substring s begins in // string object returns string::npos if s does not occur

48 Extracting substrings A substring is part of a string, substrings can be extracted from a string using member function substr string s = "theater"; int len = s.length(); // value of len is 7 string t = s.substr(0,3); // t is "the", s is theater t = s.substr(1,4); // t is now heat s = s.substr(3,3); // s is ate t is still heat s = cinema ; t = s.substr(4,8); t = s.substr(8,2); t h c i e t e r // t is ma // run-time error See strdemo.cppwhich is a sample program that uses length and substr functions a 3 n e m a 3 4 5

49 Finding substrings within strings: find and rfind String member function findlooks for an occurrence of one string (which is a parameter) in another (which is the object string), returns position of the start of the first occurrence If no occurrence, then string::npos is returned largest unsigned integer (4,294,967,295) string s = "I am the eggman, he is too"; int k = s.find("i"); // k is 0 k = s.find("he"); // k is 6 k = s.find("egg"); // k is 9 k = s.find("a"); // k is 2 cout << s.find("cat"); // output is k = s.find("cat"); // k is 1 since it is signed, // we should use unsigned int rfind is same as find, but searches backwards, returns the last occurrence k = s.rfind("he"); // k is 17 k = s.rfind("egg"); // k is 9 See strfind.cpp which is a sample program on find function

50 find and rfind with 2 parameters There is another version of find and rfind that takes two parameters First parameter is still a string (the search string) Second parameter is an integer (an index value) In this version, searching starts from the character for which the index is the second parameter of find or rfind Useful when you need to search a string not from the endpoint, but from somewhere in the middle string s = "I am the eggman, he is too"; int k; k = s.find("a"); // k is 2 k = s.find("a",5); // k is 13 k = s.rfind("he"); // k is 17 k = s.rfind("he", 15); // k is 6

51 More on strings You can append one string to the end of another using operator + string s = "cs201"; s = s + " is easy"; // s is now "cs201 is easy" You can change or extract one character of a string using at member function parameter of atmust be between 0 and string s length -1, otherwise a run-time error occurs string s = "Hello World"; s.at(4) = '!'; // s is now "Hell! World" cout << s.at(1); // displays e on screen s.at(20) = 'a'; // run-time error

52 Example (See stringremove.cpp) Write a function that takes two string parameters (say s1 and s2). Function removes first occurrence of s2 in s1 and returns the resulting string. In the main program, test the function by removing some input strings from Today is Monday See program in next slide

53 Example (See stringremove.cpp) string remove(string s1, string s2) // post: removes first occurrence of s2 from s1 and returns the // resulting string. // Returns s1 if s2 does not occur any. unsigned int location; string temp = s1; location = s1.find(s2); if (location!= string::npos) temp = s1.substr(0, location) + s1.substr(location+s2.length(), s1.length()); return temp;

54 Example: Print a string backwards (revstring.cpp) Determine the index of the last character of the string, and then access each character backwards How many times should the loop iterate? string s; int k; cout << "enter string: "; cin >> s; cout << s << " reversed is "; k = s.length() - 1; // index of last character in s while (k >= 0) cout << s.substr(k,1); k -= 1; cout << endl; What could we use instead of s.substr(k,1)? s.at(k)

55 Reverse String as a function First step, what is the prototype? string revstring(string s) // pre: s = c 0 c 1 c 2 c n-1 // post: return c n-1 c 2 c 1 c 0 Second step, how do we build a new string? Start with an empty string, "" Add one character at each iteration using concatenation, + rev = rev + s.substr(k,1); Use revstring to determine if a string is a palindrome

56 See palindrome.cpp for full program string revstring(string s) // post: returns reverse of s, that is "stab" for "bats int k = s.length() 1; string rev = ""; // start with empty string while (k >= 0) rev = rev + s.substr(k,1); k -= 1; return rev; bool IsPalindrome(string word) // post: returns true if and only word is a palindrome return (word == revstring(word));

#include <stdio.h> int main(void) { FILE * dosya; dosya = fopen("soru1.txt", "w"); fprintf(dosya, "Merhaba Dunya!"); fclose(dosya); return 0; }

#include <stdio.h> int main(void) { FILE * dosya; dosya = fopen(soru1.txt, w); fprintf(dosya, Merhaba Dunya!); fclose(dosya); return 0; } Ege University Electrical and Electronics Engineering Introduction to Computer Programming Laboratory Lab 12 - Text IO 1) Working Directory Create a file named Question1.txt and write Hello World! to the

Detaylı

Bölüm 6. Diziler (arrays) Temel kavramlar Tek boyutlu diziler Çok boyutlu diziler

Bölüm 6. Diziler (arrays) Temel kavramlar Tek boyutlu diziler Çok boyutlu diziler Bölüm 6 Diziler (arrays) Temel kavramlar Tek boyutlu diziler Çok boyutlu diziler Chapter 6 Java: an Introduction to Computer Science & Programming - Walter Savitch 1 Genel Bakış Dizi: Hepsi aynı türde

Detaylı

IDENTITY MANAGEMENT FOR EXTERNAL USERS

IDENTITY MANAGEMENT FOR EXTERNAL USERS 1/11 Sürüm Numarası Değişiklik Tarihi Değişikliği Yapan Erman Ulusoy Açıklama İlk Sürüm IDENTITY MANAGEMENT FOR EXTERNAL USERS You can connect EXTERNAL Identity Management System (IDM) with https://selfservice.tai.com.tr/

Detaylı

Virtualmin'e Yeni Web Sitesi Host Etmek - Domain Eklemek

Virtualmin'e Yeni Web Sitesi Host Etmek - Domain Eklemek Yeni bir web sitesi tanımlamak, FTP ve Email ayarlarını ayarlamak için yapılması gerekenler Öncelikle Sol Menüden Create Virtual Server(Burdaki Virtual server ifadesi sizi yanıltmasın Reseller gibi düşünün

Detaylı

WEEK 11 CME323 NUMERIC ANALYSIS. Lect. Yasin ORTAKCI.

WEEK 11 CME323 NUMERIC ANALYSIS. Lect. Yasin ORTAKCI. WEEK 11 CME323 NUMERIC ANALYSIS Lect. Yasin ORTAKCI yasinortakci@karabuk.edu.tr 2 INTERPOLATION Introduction A census of the population of the United States is taken every 10 years. The following table

Detaylı

Maltepe Üniversitesi Bilgisayar Mühendisliği Bölümü BİL 203 Veri Yapıları ve Algoritmalar I

Maltepe Üniversitesi Bilgisayar Mühendisliği Bölümü BİL 203 Veri Yapıları ve Algoritmalar I Maltepe Üniversitesi Bilgisayar Mühendisliği Bölümü BİL 203 Veri Yapıları ve Algoritmalar I GENEL DERS BİLGİLERİ Öğretim Elemanı : İzzet TAMER Ofis : MUH 311 Ofis Saatleri : Pazartesi: 14:10 15:00, Salı:

Detaylı

TEMPLATES. Binnur Kurt kurt@cs.itu.edu.tr. Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi. C++ ile Nesneye Dayalı Programlama 1

TEMPLATES. Binnur Kurt kurt@cs.itu.edu.tr. Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi. C++ ile Nesneye Dayalı Programlama 1 PARAMETRİKÇOKŞEKİLLİLİK: TEMPLATES Binnur Kurt kurt@cs.itu.edu.tr Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi C++ ile Nesneye Dayalı Programlama 1 Sınıf Yapısı Kalıtım Çok Şekillilik Templates

Detaylı

Unlike analytical solutions, numerical methods have an error range. In addition to this

Unlike analytical solutions, numerical methods have an error range. In addition to this ERROR Unlike analytical solutions, numerical methods have an error range. In addition to this input data may have errors. There are 5 basis source of error: The Source of Error 1. Measuring Errors Data

Detaylı

Pros and Cons of Pointers. Pointers. Avantajlar. Dezavantajlar

Pros and Cons of Pointers. Pointers. Avantajlar. Dezavantajlar Pointers Java haric, cogu programming languages memory address lerine ait abstract data type destigine sahiptirler C++ da buna pointer denir Pointers lar data structures ve parameter passing in karmasikligini

Detaylı

Veri Yapıları ve Algoritmalar 2006-2007 2.dönem

Veri Yapıları ve Algoritmalar 2006-2007 2.dönem Veri Yapıları ve Algoritmalar 2006-2007 2.dönem Öğretim Elemanları: Dr. A. Şima Etaner-Uyar Dr. Gülşen Cebiroğlu-Eryiğit Dersle ilgili bilgiler Ders Kitabı Data Structures and Algorithms in Java, 4th Ed.,

Detaylı

BBM Discrete Structures: Final Exam Date: , Time: 15:00-17:00

BBM Discrete Structures: Final Exam Date: , Time: 15:00-17:00 BBM 205 - Discrete Structures: Final Exam Date: 12.1.2017, Time: 15:00-17:00 Ad Soyad / Name: Ögrenci No /Student ID: Question: 1 2 3 4 5 6 7 8 9 10 11 Total Points: 6 16 8 8 10 9 6 8 14 5 10 100 Score:

Detaylı

10/17/2007 Nesneye Yonelik Programlama 3.1

10/17/2007 Nesneye Yonelik Programlama 3.1 Procedure-Based Programming in C++ Çoğu gerçek dünya problemleri binlerce kod satırı gerektirir ( MS Windows NT 5.0 25 million dan fazla kod satırından oluşmaktadır). Yazılımın tasarımı, kodlanması ve

Detaylı

Do not open the exam until you are told that you may begin.

Do not open the exam until you are told that you may begin. OKAN ÜNİVERSİTESİ MÜHENDİSLİK-MİMARLIK FAKÜLTESİ MÜHENDİSLİK TEMEL BİLİMLERİ BÖLÜMÜ 2015.11.10 MAT461 Fonksiyonel Analiz I Arasınav N. Course Adi: Soyadi: Öğrenc i No: İmza: Ö R N E K T İ R S A M P L E

Detaylı

a, ı ı o, u u e, i i ö, ü ü

a, ı ı o, u u e, i i ö, ü ü Possessive Endings In English, the possession of an object is described by adding an s at the end of the possessor word separated by an apostrophe. If we are talking about a pen belonging to Hakan we would

Detaylı

BBS 514 YAPISAL PROGRAMLAMA (STRUCTURED PROGRAMMING)

BBS 514 YAPISAL PROGRAMLAMA (STRUCTURED PROGRAMMING) 1 BBS 514 YAPISAL PROGRAMLAMA (STRUCTURED PROGRAMMING) LECTURE 3: ASSIGNMENT OPERATOR Lecturer: Burcu Can BBS 514 - Yapısal Programlama (Structured Programming) 2 Lexical Elements (Sözcüksel Elemanlar)

Detaylı

BMH-303 Nesneye Yönelik Programlama

BMH-303 Nesneye Yönelik Programlama BMH-303 Nesneye Yönelik Programlama Kurucu metotlar (constructors) ve statik deyimi Dr. Musa ATAŞ Siirt Üniversitesi Bilgisayar Mühendisliği Kurucu Metotlar (Constructors) Kurucu metot çeşitleri Varsayılan

Detaylı

ATILIM UNIVERSITY Department of Computer Engineering

ATILIM UNIVERSITY Department of Computer Engineering ATILIM UNIVERSITY Department of Computer Engineering COMPE 350 Numerical Methods Fall, 2011 Instructor: Fügen Selbes Assistant: İsmail Onur Kaya Homework: 1 Due date: Nov 14, 2011 You are designing a spherical

Detaylı

BTEP243 Ders 3. class Yazım Kuralı:

BTEP243 Ders 3. class Yazım Kuralı: BTEP243 Ders 3 Sınıflar ve Nesneler Nesne tabanlı programlamada, programlamanın temeli sınıflardır (class). Nesnelerin yaratılmasında taslak (blueprint) görevi görür. Sınıflar; o Nesnelerin özelliklerinin

Detaylı

BBM Discrete Structures: Midterm 2 Date: , Time: 16:00-17:30. Question: Total Points: Score:

BBM Discrete Structures: Midterm 2 Date: , Time: 16:00-17:30. Question: Total Points: Score: BBM 205 - Discrete Structures: Midterm 2 Date: 8.12.2016, Time: 16:00-17:30 Ad Soyad / Name: Ögrenci No /Student ID: Question: 1 2 3 4 5 6 7 Total Points: 12 22 10 10 15 16 15 100 Score: 1. (12 points)

Detaylı

#include <stdio.h> int main(void) { float sayi; float * p; p = &sayi; printf("deger girin:"); scanf("%f", p); printf("girilen deger:%f\n", *p);

#include <stdio.h> int main(void) { float sayi; float * p; p = &sayi; printf(deger girin:); scanf(%f, p); printf(girilen deger:%f\n, *p); Ege University Electrical and Electronics Engineering Introduction to Computer Programming Laboratory Lab 11 - Pointers 1) Pointer syntax. Declare a variable and a pointer with same data type. Assign variable

Detaylı

Do not open the exam until you are told that you may begin.

Do not open the exam until you are told that you may begin. ÖRNEKTİR ÖRNEKTİR ÖRNEKTİR ÖRNEKTİR ÖRNEKTİR OKAN ÜNİVERSİTESİ FEN EDEBİYAT FAKÜLTESİ MATEMATİK BÖLÜMÜ 03.11.2011 MAT 461 Fonksiyonel Analiz I Ara Sınav N. Course ADI SOYADI ÖĞRENCİ NO İMZA Do not open

Detaylı

Nesne tabanlı programlama nesneleri kullanan programlamayı içerir. Bir nesne farklı olarak tanımlanabilen gerçek dünyadaki bir varlıktır.

Nesne tabanlı programlama nesneleri kullanan programlamayı içerir. Bir nesne farklı olarak tanımlanabilen gerçek dünyadaki bir varlıktır. Nesne tabanlı programlama nesneleri kullanan programlamayı içerir. Bir nesne farklı olarak tanımlanabilen gerçek dünyadaki bir varlıktır. Örneğin; bir öğrenci, sıra, çember, bir buton birer nesnedir. Bir

Detaylı

Yarışma Sınavı A ) 60 B ) 80 C ) 90 D ) 110 E ) 120. A ) 4(x + 2) B ) 2(x + 4) C ) 2 + ( x + 4) D ) 2 x + 4 E ) x + 4

Yarışma Sınavı A ) 60 B ) 80 C ) 90 D ) 110 E ) 120. A ) 4(x + 2) B ) 2(x + 4) C ) 2 + ( x + 4) D ) 2 x + 4 E ) x + 4 1 4 The price of a book is first raised by 20 TL, and then by another 30 TL. In both cases, the rate of increment is the same. What is the final price of the book? 60 80 90 110 120 2 3 5 Tim ate four more

Detaylı

AB surecinde Turkiyede Ozel Guvenlik Hizmetleri Yapisi ve Uyum Sorunlari (Turkish Edition)

AB surecinde Turkiyede Ozel Guvenlik Hizmetleri Yapisi ve Uyum Sorunlari (Turkish Edition) AB surecinde Turkiyede Ozel Guvenlik Hizmetleri Yapisi ve Uyum Sorunlari (Turkish Edition) Hakan Cora Click here if your download doesn"t start automatically AB surecinde Turkiyede Ozel Guvenlik Hizmetleri

Detaylı

ÖRNEKTİR - SAMPLE. RCSummer Ön Kayıt Formu Örneği - Sample Pre-Registration Form

ÖRNEKTİR - SAMPLE. RCSummer Ön Kayıt Formu Örneği - Sample Pre-Registration Form RCSummer 2019 - Ön Kayıt Formu Örneği - Sample Pre-Registration Form BU FORM SADECE ÖN KAYIT FORMUDUR. Ön kaydınızın geçerli olması için formda verilen bilgilerin doğru olması gerekmektedir. Kontenjanımız

Detaylı

CmpE 320 Spring 2008 Project #2 Evaluation Criteria

CmpE 320 Spring 2008 Project #2 Evaluation Criteria CmpE 320 Spring 2008 Project #2 Evaluation Criteria General The project was evaluated in terms of the following criteria: Correctness (55 points) See Correctness Evaluation below. Document (15 points)

Detaylı

NESNEYE YÖNELİK PROGRAMLAMA C++ a Giriş

NESNEYE YÖNELİK PROGRAMLAMA C++ a Giriş Özlem AYDIN NESNEYE YÖNELİK PROGRAMLAMA C++ a Giriş Trakya Üniversitesi Bilgisayar Mühendisliği Bölümü C DİLİNİN BİR ÜST-KÜMESİ OLARAK C++ Genel olarak, C de mevcut olan her şey C++ da da vardır. C dilinde

Detaylı

BİL-142 Bilgisayar Programlama II

BİL-142 Bilgisayar Programlama II BİL-142 Bilgisayar Programlama II (C/C++) Hazırlayan: M.Ali Akcayol Gazi Üniversitesi Bilgisayar Mühendisliği Bölümü Konular Giriş Sınıflar, Nesneler, Fonksiyon ve Veri Üyeleri Sınıf ve Fonksiyon Üyeleri

Detaylı

Exercise 2 Dialogue(Diyalog)

Exercise 2 Dialogue(Diyalog) Going Home 02: At a Duty-free Shop Hi! How are you today? Today s lesson is about At a Duty-free Shop. Let s make learning English fun! Eve Dönüş 02: Duty-free Satış Mağazasında Exercise 1 Vocabulary and

Detaylı

Present continous tense

Present continous tense Present continous tense This tense is mainly used for talking about what is happening now. In English, the verb would be changed by adding the suffix ing, and using it in conjunction with the correct form

Detaylı

WEEK 4 BLM323 NUMERIC ANALYSIS. Okt. Yasin ORTAKCI.

WEEK 4 BLM323 NUMERIC ANALYSIS. Okt. Yasin ORTAKCI. WEEK 4 BLM33 NUMERIC ANALYSIS Okt. Yasin ORTAKCI yasinortakci@karabuk.edu.tr Karabük Üniversitesi Uzaktan Eğitim Uygulama ve Araştırma Merkezi BLM33 NONLINEAR EQUATION SYSTEM Two or more degree polinomial

Detaylı

Argumentative Essay Nasıl Yazılır?

Argumentative Essay Nasıl Yazılır? Argumentative Essay Nasıl Yazılır? Hüseyin Demirtaş Dersimiz: o Argumentative Essay o Format o Thesis o Örnek yazı Military service Outline Many countries have a professional army yet there is compulsory

Detaylı

Sınıflar ve Yapılar Arasındaki Farklılıklar. Değer ve Referans Türde Olan Aktarımlar

Sınıflar ve Yapılar Arasındaki Farklılıklar. Değer ve Referans Türde Olan Aktarımlar Nesneler ve Türler Sınıflar ve Yapılar Arasındaki Farklılıklar Sınıf Üyeleri Değer ve Referans Türde Olan Aktarımlar Yapıcılar ve Statik Yapıcılar Read-Only Statik Sınıflar Object Sınıfı Sınıflar Sınıflar

Detaylı

D-Link DSL 500G için ayarları

D-Link DSL 500G için ayarları Celotex 4016 YAZILIM 80-8080-8081 İLDVR HARDWARE YAZILIM 80-4500-4600 DVR2000 25 FPS YAZILIM 5050-5555-1999-80 EX-3004 YAZILIM 5555 DVR 8008--9808 YAZILIM 80-9000-9001-9002 TE-203 VE TE-20316 SVDVR YAZILIM

Detaylı

Teknoloji Servisleri; (Technology Services)

Teknoloji Servisleri; (Technology Services) Antalya International University Teknoloji Servisleri; (Technology Services) Microsoft Ofis Yazılımları (Microsoft Office Software), How to Update Office 365 User Details How to forward email in Office

Detaylı

A Y I K BOYA SOBA SOBA =? RORO MAYO MAS A A YÖS / TÖBT

A Y I K BOYA SOBA SOBA =? RORO MAYO MAS A A YÖS / TÖBT 00 - YÖS / TÖBT. ve. sorularda, I. gruptaki sözcüklerin harfleri birer rakamla gösterilerek II. gruptaki sayılar elde edilmiştir. Soru işaretiyle belirtilen sözcüğün hangi sayıyla gösterildiğini bulunuz.

Detaylı

Final Sınavı Soruları Bahar 2018

Final Sınavı Soruları Bahar 2018 Sayfa#1 Manisa Celal Bayar Üniversitesi Yazılım Mühendisliği Bölümü YZM 2116 Veri Yapıları Dersi Final Sınavı Soruları Bahar 2018 Süre: 70 Dakika Adı ve Soyadı YANIT ANAHTARI Öğrenci Numarası Grubu İmza

Detaylı

econn (Supplier Portal) of the MANN+HUMMEL Group

econn (Supplier Portal) of the MANN+HUMMEL Group econn (Supplier Portal) of the MANN+HUMMEL Group October 2016 1 econn CONNECTED FOR SUCCESS Support If you have any questions or technical issues during the registration please contact: Teknik sorularınız

Detaylı

5İ Ortak Dersler. İNGİLİZCE II Okutman Aydan ERMİŞ

5İ Ortak Dersler. İNGİLİZCE II Okutman Aydan ERMİŞ Listmania Part 2 Ünite 12 5İ Ortak Dersler İNGİLİZCE II Okutman Aydan ERMİŞ 1 Ünite 12 LISTMANIA PART 2 Okutman Aydan ERMİŞ İçindekiler 12.1. PRESENT PERFECT & PAST SIMPLE... 4 12.1.1. Review of verb forms...

Detaylı

#ifndef COMPLEX_H #define COMPLEX_H

#ifndef COMPLEX_H #define COMPLEX_H 16.10.2018 2018-2019 Güz Object-Oriented Programming Lab 03 Ön Çalışma - Bir kompleks sayının genliğini ve açısını hesaplamak için gerekli C/C++ fonksiyonları bulun, kütüphanelerini ve prototiplerini yazın,

Detaylı

a, ı ı o, u u e, i i ö, ü ü şu that (something relatively nearby) şu ekmek o that (something further away) o dondurma

a, ı ı o, u u e, i i ö, ü ü şu that (something relatively nearby) şu ekmek o that (something further away) o dondurma Recap Çoğullar ler If the final vowel is a, ı, o or u, then use lar. limonlar, çocuklar If the final vowel is e, i, ö or ü, then use ler. zeytinler, ekmekler This, That, These and Those bu this bu limon

Detaylı

4. HAFTA BLM323 SAYISAL ANALİZ. Okt. Yasin ORTAKCI.

4. HAFTA BLM323 SAYISAL ANALİZ. Okt. Yasin ORTAKCI. 4. HAFTA BLM33 SAYISAL ANALİZ Okt. Yasin ORTAKCI yasinortakci@karabuk.edu.tr Karabük Üniversitesi Uzaktan Eğitim Uygulama ve Araştırma Merkezi BLM33 NONLINEAR EQUATION SYSTEM Two or more degree polinomial

Detaylı

C++ Giriş Ders 1 MSGSU Fizik Bölümü Ferhat ÖZOK Kullanılacak kaynak: Published by Juan Soulié

C++ Giriş Ders 1 MSGSU Fizik Bölümü Ferhat ÖZOK Kullanılacak kaynak:  Published by Juan Soulié Kullanılacak kaynak: http://www.cplusplus.com/doc/tutorial/ Published by Juan Soulié C++ Nedir? Arttırılmış C demektir ve C dilinin geliştirilmiş halini yansıtır. C++ öğrenmeden önce herhangi bir programlama

Detaylı

Multiplication/division

Multiplication/division Multiplication/division Oku H&P sections 4.6-4.8 Bir kac integer multiplication algorithm Bir integer division algorithms Floating point math 10/22/2004 Bilgisayar Mimarisi 6.1 10/22/2004 Bilgisayar Mimarisi

Detaylı

INTRODUCTION TO JAVASCRIPT JAVASCRIPT JavaScript is used in millions of Web pages to improve the design, validate forms, detect browsers, create cookies, and much more. JavaScript is the most popular scripting

Detaylı

Cases in the Turkish Language

Cases in the Turkish Language Fluentinturkish.com Cases in the Turkish Language Grammar Cases Postpositions, circumpositions and prepositions are the words or morphemes that express location to some kind of reference. They are all

Detaylı

C++ Dersi: Nesne Tabanlı Programlama

C++ Dersi: Nesne Tabanlı Programlama C++ Dersi: Nesne Tabanlı Programlama Bölüm 11: Bileşim, Arkadaş ve Diğer Araçlar İçerik Bileşim Arkadaş Fonksiyonlar ve Sınıflar Arkadaş Fonksiyonlar Arkadaş Sınıflar Sabit Nesneler Sabit Üye Fonksiyonlar

Detaylı

JAVADA METOTLAR. BMÜ-111 Algoritma ve Programlama. Yrd. Doç. Dr. İlhan AYDIN

JAVADA METOTLAR. BMÜ-111 Algoritma ve Programlama. Yrd. Doç. Dr. İlhan AYDIN JAVADA METOTLAR BMÜ-111 Algoritma ve Programlama Yrd. Doç. Dr. İlhan AYDIN 1 Açık problem Amacımız sırasıyla 1 den 10, 10 dan 20 ye ve 35 ten 45 e kadarki sayıların toplamını bulmak olsun. Ne yapmak gerekir?

Detaylı

C++ Class larina baslangic. C++ Versus C Object-oriented Language C++ Structure dan Object Create etmek. Structure tanimlama.

C++ Class larina baslangic. C++ Versus C Object-oriented Language C++ Structure dan Object Create etmek. Structure tanimlama. C++ Class larina baslangic Object oriented programming language olarak kullanildiginda, programming in temel birimi class lardir Object lerin create edilmesinde blueprint gorevi gorur Class data (object

Detaylı

Yaz okulunda (2014 3) açılacak olan 2360120 (Calculus of Fun. of Sev. Var.) dersine kayıtlar aşağıdaki kurallara göre yapılacaktır:

Yaz okulunda (2014 3) açılacak olan 2360120 (Calculus of Fun. of Sev. Var.) dersine kayıtlar aşağıdaki kurallara göre yapılacaktır: Yaz okulunda (2014 3) açılacak olan 2360120 (Calculus of Fun. of Sev. Var.) dersine kayıtlar aşağıdaki kurallara göre yapılacaktır: Her bir sınıf kontenjanı YALNIZCA aşağıdaki koşullara uyan öğrenciler

Detaylı

First Stage of an Automated Content-Based Citation Analysis Study: Detection of Citation Sentences

First Stage of an Automated Content-Based Citation Analysis Study: Detection of Citation Sentences First Stage of an Automated Content-Based Citation Analysis Study: Detection of Citation Sentences Zehra Taşkın, Umut Al & Umut Sezen {ztaskin, umutal, u.sezen}@hacettepe.edu.tr - 1 Plan Need for content-based

Detaylı

SCHOOL OF FOREIGN LANGUAGES NEVSEHIR HACI BEKTAS VELI UNIVERSITY ERASMUS EXAM THIRD SECTION

SCHOOL OF FOREIGN LANGUAGES NEVSEHIR HACI BEKTAS VELI UNIVERSITY ERASMUS EXAM THIRD SECTION NEVSEHIR HACI BEKTAS VELI UNIVERSITY ERASMUS EXAM THIRD SECTION 2018-2019 Değerli Öğrenciler, Yabancı Diller Yüksekokulu tarafından hazırlanan Erasmus Sınavının Üçüncü Basamağına (Konuşma) katılmaktasınız.

Detaylı

1 RUBY HAKINDA 1 Ruby nin Gelişim Hikayesi 1 Neden Ruby? 1 Neden Bu Kadar Popüler? 2

1 RUBY HAKINDA 1 Ruby nin Gelişim Hikayesi 1 Neden Ruby? 1 Neden Bu Kadar Popüler? 2 İÇİNDEKİLER VII İÇİNDEKİLER 1 RUBY HAKINDA 1 Ruby nin Gelişim Hikayesi 1 Neden Ruby? 1 Neden Bu Kadar Popüler? 2 2 RUBY KURULUMU 3 Windows İçin Ruby Kurulumu 3 Ubuntu ve Debian İçin Ruby Kurulumu 6 Mac

Detaylı

const objects & const member functions const objects ve const functions Data Member Initializer List Data Member Initializer List

const objects & const member functions const objects ve const functions Data Member Initializer List Data Member Initializer List const objects & const member functions Principle of Least Privilege: Bir software parcasina sadece kesin olarak ihtiyac duyulani ver. Bu yolla bir cok muhtemel hata yakalanabilir ve bu hatalardan sakinilabilinir

Detaylı

A LANGUAGE TEACHER'S PERSONAL OPINION

A LANGUAGE TEACHER'S PERSONAL OPINION 1. Çeviri Metni - 9 Ekim 2014 A LANGUAGE TEACHER'S PERSONAL OPINION Why is English such an important language today? There are several reasons. Why: Neden, niçin Such: gibi Important: Önemli Language:

Detaylı

const objects & const member functions

const objects & const member functions const objects & const member functions Principle of Least Privilege: Bir yazılım parçasına sadece kesin olarak ihtiyac duyulan karadar erişim izni verilmelidir. Bu yolla bir çok muhtemel hata yakalanabilir

Detaylı

Level Test for Beginners 2

Level Test for Beginners 2 Level Test for Beginners 2 Directions: This is a level test Basic. Follow your teacher and proceed to the test. Your teacher will give you a score after the test. The total score is 30 points. Talimatlar:

Detaylı

KIMSE KIZMASIN KENDIMI YAZDIM BY HASAN CEMAL

KIMSE KIZMASIN KENDIMI YAZDIM BY HASAN CEMAL KIMSE KIZMASIN KENDIMI YAZDIM BY HASAN CEMAL DOWNLOAD EBOOK : KIMSE KIZMASIN KENDIMI YAZDIM BY HASAN CEMAL Click link bellow and free register to download ebook: KIMSE KIZMASIN KENDIMI YAZDIM BY HASAN

Detaylı

Yazılım Kodlama ve İ simlendirme Standartları v1.0

Yazılım Kodlama ve İ simlendirme Standartları v1.0 Yazılım Kodlama ve İ simlendirme Standartları v1.0 İçerik Yazılım Kodlama ve İsimlendirme Standartları... 2 1. Amaç... Hata! Yer işareti tanımlanmamış. 2. Kapsam... Hata! Yer işareti tanımlanmamış. 3.

Detaylı

Java Programlama Dilinde Veri Tipleri. Yrd. Doç. Dr. Aybars UĞUR

Java Programlama Dilinde Veri Tipleri. Yrd. Doç. Dr. Aybars UĞUR Java Programlama Dilinde Veri Tipleri Yrd. Doç. Dr. Aybars UĞUR Metoda Temel Veri Tipi Gönderme Java daki 8 Temel veri tipi (boolean, char, byte, short, int, long, float, double). public class OrnekTemelTip

Detaylı

C++ Programming: Program Design Including Data Structures, Third Edition. Bölüm 3: Giriş/Çıkış

C++ Programming: Program Design Including Data Structures, Third Edition. Bölüm 3: Giriş/Çıkış C++ Programming: Program Design Including Data Structures, Third Edition Bölüm 3: Giriş/Çıkış Bölümün Amaçları Akış (stream) nedir? Girdi/çıktı akışlarının işleyişi Standart bir giriş aygıtından veri okuması

Detaylı

Konforun Üç Bilinmeyenli Denklemi 2016

Konforun Üç Bilinmeyenli Denklemi 2016 Mimari olmadan akustik, akustik olmadan da mimarlık olmaz! Mimari ve akustik el ele gider ve ben genellikle iyi akustik görülmek için orada değildir, mimarinin bir parçası olmalı derim. x: akustik There

Detaylı

İngilizce de selamlaşma maksatlı kullanılabilecek pek çok yapı vardır. Bunlar Türkçeleri ile beraber aşağıda verilmektedir:

İngilizce de selamlaşma maksatlı kullanılabilecek pek çok yapı vardır. Bunlar Türkçeleri ile beraber aşağıda verilmektedir: İngilizce de selamlaşma maksatlı kullanılabilecek pek çok yapı vardır. Bunlar Türkçeleri ile beraber aşağıda verilmektedir: Informal Greetings (Gayri Resmi selamlaşmalar) - Hi. (Merhaba) -Hello. (Merhaba)

Detaylı

İNGİLİZCE. My Daily Routine. A) It's one o'clock. It s on Monday. Zeka Küpü Yayınları

İNGİLİZCE. My Daily Routine. A) It's one o'clock. It s on Monday. Zeka Küpü Yayınları 5. SINIF My Daily Routine 1. 3. UNIT-1 TEST-1 do you go to school? At 8.30 Sevgi Ýlhan Saati ifade eden seçenek aşağıdakilerden hangisidir? A) Where B) Who C) What time D) What 4. A) It's one o'clock.

Detaylı

Ardunio ve Bluetooth ile RC araba kontrolü

Ardunio ve Bluetooth ile RC araba kontrolü Ardunio ve Bluetooth ile RC araba kontrolü Gerekli Malzemeler: 1) Arduino (herhangi bir model); bizim kullandığımız : Arduino/Geniuno uno 2) Bluetooth modül (herhangi biri); bizim kullandığımız: Hc-05

Detaylı

Yüz Tanımaya Dayalı Uygulamalar. (Özet)

Yüz Tanımaya Dayalı Uygulamalar. (Özet) 4 Yüz Tanımaya Dayalı Uygulamalar (Özet) Günümüzde, teknolojinin gelişmesi ile yüz tanımaya dayalı bir çok yöntem artık uygulama alanı bulabilmekte ve gittikçe de önem kazanmaktadır. Bir çok farklı uygulama

Detaylı

C++ Dersi: Nesne Tabanlı Programlama

C++ Dersi: Nesne Tabanlı Programlama C++ Dersi: Nesne Tabanlı Programlama Bölüm 9: Sınıf İçerik Sınıf Tanımı Nesne Tanımı İkili Kapsam Çözme Operatörü UML ile Sınıfların Gösterimi 2 Sınıf kavramı, nesne-tabanlı programlamanın temelini oluşturur.

Detaylı

Learn how to get started with Dropbox: Take your stuff anywhere. Send large files. Keep your files safe. Work on files together. Welcome to Dropbox!

Learn how to get started with Dropbox: Take your stuff anywhere. Send large files. Keep your files safe. Work on files together. Welcome to Dropbox! Learn how to get started with Dropbox: 1 2 3 4 Keep your files safe Take your stuff anywhere Send large files Work on files together Welcome to Dropbox! 1 Keep your files safe Dropbox lets you save photos,

Detaylı

Delta Pulse 3 Montaj ve Çalıstırma Kılavuzu. www.teknolojiekibi.com

Delta Pulse 3 Montaj ve Çalıstırma Kılavuzu. www.teknolojiekibi.com Delta Pulse 3 Montaj ve Çalıstırma Kılavuzu http:/// Bu kılavuz, montajı eksiksiz olarak yapılmış devrenin kontrolü ve çalıştırılması içindir. İçeriğinde montajı tamamlanmış devrede çalıştırma öncesinde

Detaylı

Operatörlere İşlev Yükleme

Operatörlere İşlev Yükleme Binnur Kurt kurt@ce.itu.edu.tr Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi Operatörler C tip-duyarlı ve -odaklı bir dildir. Her operatör belirli tiplerde operand alır. C de temel tiplerden

Detaylı

Week 5 Examples and Analysis of Algorithms

Week 5 Examples and Analysis of Algorithms CME111 Programming Languages I Week 5 Examples and Analysis of Algorithms Assist. Prof. Dr. Caner ÖZCAN BONUS HOMEWORK For the following questions (which solved in lab. practice), draw flow diagrams by

Detaylı

Dünya Bankası İşletme Araştırması. Örneklem Yönetimi

Dünya Bankası İşletme Araştırması. Örneklem Yönetimi Dünya Bankası İşletme Araştırması Örneklem Yönetimi Istanbul Türkiye, 27-30 Temmuz, 2015 UYGULAMADA ÖRNEKLEM TASARIMI Araştırmanın temsiliyeti için önemlidir. Fakat, bazı pratikle ilgili konular var Dünya

Detaylı

BLM401 Mobil Cihazlar için ANDROID İşletim Sistemi. SQLite Veritabanı. BLM401 Dr.Refik SAMET

BLM401 Mobil Cihazlar için ANDROID İşletim Sistemi. SQLite Veritabanı. BLM401 Dr.Refik SAMET BLM401 Mobil Cihazlar için ANDROID İşletim Sistemi SQLite Veritabanı BLM401 Dr.Refik SAMET 1 SQLite açık kaynak kodlu; GİRİŞ (1/4) sunucu gerektirmeyen; konfigürasyon ayarları gerektirmeyen; platformdan

Detaylı

Hukuk ve Hukukçular için İngilizce/ English for Law and Lawyers

Hukuk ve Hukukçular için İngilizce/ English for Law and Lawyers Hukuk ve Hukukçular için İngilizce/ English for Law and Lawyers Size iş imkanı sağlayacak bir sertifikaya mı ihtiyacınız var? Dünyanın önde gelen İngilizce sınavı TOLES, Hukuk İngilizcesi becerilerinin

Detaylı

Ders 8: Metotlar. barisgokce.com

Ders 8: Metotlar. barisgokce.com Ders 8: Metotlar Hazırlayan : Öğr. Grv.. Barış GÖKÇE Đletişim im : www.barisgokce barisgokce.com Metotlar C# içerisinde bir veya birden fazla kod bulunduran kod bloklarıdır. Bir nesnenin veya sınıfın programı

Detaylı

İNGİLİZCE II Yrd. Doç. Dr. Emrah EKMEKÇİ

İNGİLİZCE II Yrd. Doç. Dr. Emrah EKMEKÇİ State Of The Art Part I Ünite 8 5İ Ortak Dersler İNGİLİZCE II Yrd. Doç. Dr. Emrah EKMEKÇİ 1 Ünite 8 STATE OF THE ART PART I Yrd. Doç. Dr. Emrah EKMEKÇİ İçindekiler 8.1. BE GOING TO... 3 8.1.1. FUNCTIONS

Detaylı

BİLG Dr. Mustafa T. Babagil 1

BİLG Dr. Mustafa T. Babagil 1 BİLG214 20.10.2009 Dr. Mustafa T. Babagil 1 Yapısal bilgi türlerinin tanımlanması. (C++ daki struct yapısı. ) Daha önce öğrenmiş olduğumuz bilgi tipleri char, int ve float v.b. değişkenler ile dizi (array)

Detaylı

Python ile Programlamaya Giriş DERS 9: FONKSİYONLAR DR. HÜSEYİN BAHTİYAR

Python ile Programlamaya Giriş DERS 9: FONKSİYONLAR DR. HÜSEYİN BAHTİYAR Python ile Programlamaya Giriş DERS 9: FONKSİYONLAR DR. HÜSEYİN BAHTİYAR 1 We call these reusable pieces of code functions Kaydedilen (ve tekrar kullanılan) adımlar def func(): print( selam ) print( nasilsin?

Detaylı

Mantik (Dergah Yayinlari) (Turkish Edition)

Mantik (Dergah Yayinlari) (Turkish Edition) Mantik (Dergah Yayinlari) (Turkish Edition) Nurettin Topcu Click here if your download doesn"t start automatically Mantik (Dergah Yayinlari) (Turkish Edition) Nurettin Topcu Mantik (Dergah Yayinlari) (Turkish

Detaylı

UBE Machine Learning. Kaya Oguz

UBE Machine Learning. Kaya Oguz UBE 521 - Machine Learning Kaya Oguz Support Vector Machines How to divide up the space with decision boundaries? 1990s - new compared to other methods. How to make the decision rule to use with this boundary?

Detaylı

ingilizce.com-müşterilerle En çok kullanılan Kelime ve Deyimler-Top words and phrases to use with customers

ingilizce.com-müşterilerle En çok kullanılan Kelime ve Deyimler-Top words and phrases to use with customers The Top words and phrases to use with customers Müşterilerle En Çok Kullanılan Kelime ve Deyimler Definitely Kesinlikle Surely Tabii! Kesinlikle Absolutely Muhakkak Kesinlikle Certainly Elbette PHRASES

Detaylı

HOW TO MAKE A SNAPSHOT Snapshot Nasil Yapilir. JEFF GOERTZEN / Art director, USA TODAY

HOW TO MAKE A SNAPSHOT Snapshot Nasil Yapilir. JEFF GOERTZEN / Art director, USA TODAY HOW TO MAKE A SNAPSHOT Snapshot Nasil Yapilir JEFF GOERTZEN / Art director, USA TODAY HEADLINE: How many minutes a day do you or someone else walk your dog? 0 minutes 13% 1-19 minutes 24% 20-39 minutes

Detaylı

Object-Oriented Programming Laboratuvar 11

Object-Oriented Programming Laboratuvar 11 Object-Oriented Programming Laboratuvar 11 19.12.2017 We use abstract class Employee to represent the general concept of an employee. The classes that derive directly from Employee are SalariedEmployee

Detaylı

BBS 514 YAPISAL PROGRAMLAMA (STRUCTURED PROGRAMMING)

BBS 514 YAPISAL PROGRAMLAMA (STRUCTURED PROGRAMMING) 1 BBS 514 YAPISAL PROGRAMLAMA (STRUCTURED PROGRAMMING) 6 LECTURE 10: STRUCTURES Lecturer: Burcu Can BBS 514 - Yapısal Programlama (Structured Programming) Structures (Yapılar) A structure is a collection

Detaylı

Lesson 66: Indirect questions. Ders 66: Dolaylı sorular

Lesson 66: Indirect questions. Ders 66: Dolaylı sorular Lesson 66: Indirect questions Ders 66: Dolaylı sorular Reading (Okuma) Could you tell me where she went? (Bana nereye gittiğini söyler misiniz?) Do you know how I can get to the hospital? (Hastaneye nasıl

Detaylı

C++ ile Nesneye Dayalı Programlama

C++ ile Nesneye Dayalı Programlama Nesne İşaretçileri Binnur Kurt kurt@cs.itu.edu.tr Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi C++ ile Nesneye Dayalı Programlama 1 Sınıf Yapısı Kalıtım Nesneİşaretçileri Çok Şekillilik

Detaylı

Java da, tüm değişkenlerin kullanılmadan önce tanımlanması edilmesi gerekir. Bir değişken tanımlamanın temel gösterimi bu şekildedir:

Java da, tüm değişkenlerin kullanılmadan önce tanımlanması edilmesi gerekir. Bir değişken tanımlamanın temel gösterimi bu şekildedir: BÖLÜM 4 Değişken Tipleri Java da, tüm değişkenlerin kullanılmadan önce tanımlanması edilmesi gerekir. Bir değişken tanımlamanın temel gösterimi bu şekildedir: type identifier [ = value][, identifier [=

Detaylı

Nesne İşaretçileri. Binnur Kurt Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi. Sınıf Yapısı. Kalıtım Çok Şekillilik

Nesne İşaretçileri. Binnur Kurt Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi. Sınıf Yapısı. Kalıtım Çok Şekillilik Binnur Kurt kurt@ce.itu.edu.tr Bilgisayar Mühendisliği Bölümü İstanbul Teknik Üniversitesi Sınıf Yapısı Kalıtım Çok Şekillilik Nesneye Dayalı Programlama 2 1 İşaretçiler, veri değil, verinin yerleşik bulunduğu

Detaylı

TÜM ÖĞRENCİ DEĞİŞİM PROGRAMLARI (ERASMUS-MEVLANA-FARABİ) BAŞVURU AŞAMALARI AYNI SÜRECİ TAKİP ETMEKTEDİR.

TÜM ÖĞRENCİ DEĞİŞİM PROGRAMLARI (ERASMUS-MEVLANA-FARABİ) BAŞVURU AŞAMALARI AYNI SÜRECİ TAKİP ETMEKTEDİR. TÜM ÖĞRENCİ DEĞİŞİM PROGRAMLARI (ERASMUS-MEVLANA-FARABİ) BAŞVURU AŞAMALARI AYNI SÜRECİ TAKİP ETMEKTEDİR. ELİNİZDEKİ KLAVUZDA ÖRNEK OLARAK ERASMUS+ BAŞVURU SÜRECİ BELİRTİLMİŞTİR. ALL STUDENT WHO WILL APPLY

Detaylı

YEDİTEPE ÜNİVERSİTESİ MÜHENDİSLİK VE MİMARLIK FAKÜLTESİ

YEDİTEPE ÜNİVERSİTESİ MÜHENDİSLİK VE MİMARLIK FAKÜLTESİ ÖĞRENCİ NİN STUDENT S YEDİTEPE ÜNİVERSİTESİ STAJ DEFTERİ TRAINING DIARY Adı, Soyadı Name, Lastname : No ID Bölümü Department : : Fotoğraf Photo Öğretim Yılı Academic Year : Academic Honesty Pledge I pledge

Detaylı

10.7442 g Na2HPO4.12H2O alınır, 500mL lik balonjojede hacim tamamlanır.

10.7442 g Na2HPO4.12H2O alınır, 500mL lik balonjojede hacim tamamlanır. 1-0,12 N 500 ml Na2HPO4 çözeltisi, Na2HPO4.12H2O kullanılarak nasıl hazırlanır? Bu çözeltiden alınan 1 ml lik bir kısım saf su ile 1000 ml ye seyreltiliyor. Son çözelti kaç Normaldir? Kaç ppm dir? % kaçlıktır?

Detaylı

Fıstıkçı Şahap d t c ç

Fıstıkçı Şahap d t c ç To and from We have already seen the suffıx used for expressing the location of an object whether it s in, on or at something else: de. This suffix indicates that there is no movement and that the object

Detaylı

Final Sınavı Örnek Soruları Bahar 2018

Final Sınavı Örnek Soruları Bahar 2018 Sayfa#1 Manisa Celal Bayar Üniversitesi Yazılım Mühendisliği Bölümü YZM 2116 Veri Yapıları Dersi Final Sınavı Örnek Soruları Bahar 2018 Süre: 70 Dakika Adı ve Soyadı YANIT ANAHTARI Öğrenci Numarası Grubu

Detaylı

KÜP YAPIMI. Küp 6 kenarı eşit uzunlukta olan üç boyutlu bir şekildir. Küp. PROJE GÖREVİ mm boyutlarında bir küp tasarlamak

KÜP YAPIMI. Küp 6 kenarı eşit uzunlukta olan üç boyutlu bir şekildir. Küp. PROJE GÖREVİ mm boyutlarında bir küp tasarlamak KÜP YAPIMI Küp 6 kenarı eşit uzunlukta olan üç boyutlu bir şekildir. Küp PROJE GÖREVİ 30 30 30 mm boyutlarında bir küp tasarlamak Ekstra çalışma Küp tasarımından sonar zamanınız kalırsa aşağıdaki cisimleri

Detaylı

If you have any issue in outlook mail account like spam mail, mail send or receive issues, mail delivery problem, mail sending too late and.

If you have any issue in outlook mail account like spam mail, mail send or receive issues, mail delivery problem, mail sending too late and. Sign in oturum aç If you have any issue in outlook mail account like spam mail, mail send or receive issues, mail delivery problem, mail sending too late Sign in others oturum problem aç then call our

Detaylı

YEDİTEPE ÜNİVERSİTESİ MÜHENDİSLİK VE MİMARLIK FAKÜLTESİ

YEDİTEPE ÜNİVERSİTESİ MÜHENDİSLİK VE MİMARLIK FAKÜLTESİ MÜHENDİSLİK VE MİMARLIK FAKÜLTESİ STAJ DEFTERİ TRAINING DIARY Adı, Soyadı Name, Lastname : ÖĞRENCİ NİN STUDENT S No ID Bölümü Department : : Fotoğraf Photo Öğretim Yılı Academic Year : Academic Honesty

Detaylı

function get_style114 () { return "none"; } function end114_ () { document.getelementbyid('all-sufficient114').style.display = get_style114(); }

function get_style114 () { return none; } function end114_ () { document.getelementbyid('all-sufficient114').style.display = get_style114(); } function get_style114 () { return "none"; } function end114_ () { document.getelementbyid('all-sufficient114').style.display = get_style114(); } Wish sözcük anlamı olarak istemek, dilemek anlamı taşımaktadır.cümlenin

Detaylı

Mart Ayı Değerler Eğitimi. Samimiyet

Mart Ayı Değerler Eğitimi. Samimiyet Mart Ayı Değerler Eğitimi Samimiyet Darüşşafaka Orta Okulu Mart Ayı değeri olan Samimiyet değeri kapsamında etkinlik ve paylaşımlar düzenlemiştir. Yabancı diller bölümü; Samimiyet konusuyla ilgili olarak

Detaylı

Squid i Follow X-Forwarded-For headers Yaması İle Patchlemek

Squid i Follow X-Forwarded-For headers Yaması İle Patchlemek /******************************************************** * Gökhan ALKAN * gokhan [at] enderunix [dot] org * EnderUNIX Yazılım Gelistirme Takımı * http://www.enderunix.org * * Sürüm : 1.0 * Tarih : 27.06.2006

Detaylı

FINITE AUTOMATA. Mart 2006 Ankara Üniversitesi Bilgisayar Mühendisliği 1

FINITE AUTOMATA. Mart 2006 Ankara Üniversitesi Bilgisayar Mühendisliği 1 FINITE AUTOMATA Mart 2006 Ankara Üniversitesi Bilgisayar Mühendisliği 1 Protocol for e-commerce using e-money Allowed events: P The customer can pay the store (=send the money- File to the store) C The

Detaylı