• Downloads
  • ! Read Me !
  • Μαθήματα
  • Φοιτητικά
  • Τεχνικά Θέματα
  • Συζητήσεις
  • Happy Hour!
  • About THMMY.gr
 V  < 
Search:  
Welcome, Guest. Please login or register.
June 19, 2025, 11:33:50 am

Login with username, password and session length
Links
  Thmmy.gr portal
   Forum
   Downloads
   Ενεργ. Λογαριασμού
   Επικοινωνία
  
  Χρήσιμα links
   Σελίδα τμήματος
   Βιβλιοθήκη Τμήματος
   Elearning
   Φοιτητικά fora
   Πρόγραμμα Λέσχης
   Πρακτική Άσκηση
   Ηλεκτρονική Εξυπηρέτηση Φοιτητών
   Διανομή Συγγραμμάτων
   Ψηφιακό Καταθετήριο Διπλωματικών
   Πληροφορίες Καθηγητών
   Instagram @thmmy.gr
   mTHMMY
  
  Φοιτητικές Ομάδες
   ACM
   Aristurtle
   ART
   ASAT
   BEAM
   BEST Thessaloniki
   EESTEC LC Thessaloniki
   EΜΒ Auth
   IAESTE Thessaloniki
   IEEE φοιτητικό παράρτημα ΑΠΘ
   SpaceDot
   VROOM
   Panther
  
Πίνακας Ελέγχου
Welcome, Guest. Please login or register.
June 19, 2025, 11:33:50 am

Login with username, password and session length

Αναζήτηση

Google

THMMY.gr Web
Πρόσφατα
Αιτήσεις Ορκωμοσίας ΤΗΜΜΥ...
by Mr Watson
[Today at 09:55:52]

Πότε θα βγει το μάθημα; -...
by tzortzis
[Today at 07:09:33]

H Στοά των Off Topic
by Katarameno
[June 18, 2025, 20:28:39 pm]

Ισραήλ - Ιράν: Πόλεμος στ...
by Katarameno
[June 18, 2025, 19:40:47 pm]

[ΣΗΕ ΙΙ] Γενικές απορίες ...
by chatzikys
[June 18, 2025, 19:26:00 pm]

Σιδηροδρομικό Δυστύχημα σ...
by Katarameno
[June 18, 2025, 18:22:39 pm]

[Μεταφορά και Διανομή ΗΕ]...
by tzortzis
[June 18, 2025, 07:55:05 am]

Πρακτική Άσκηση ΤΗΜΜΥ 201...
by chris_p30
[June 18, 2025, 00:45:33 am]

[Ψηφιακά Ολοκληρωμένα Κυκ...
by tzortzis
[June 17, 2025, 21:25:42 pm]

[Εφ.Θερμοδυναμική] Γενικέ...
by PAPARI69
[June 17, 2025, 20:59:13 pm]

[Γραφική] Λυμένα θέματα
by okanpala
[June 17, 2025, 18:56:22 pm]

Τι ακούτε αυτήν τη στιγμή...
by Katarameno
[June 17, 2025, 14:25:00 pm]

Αντικατάστασης πυκνωτή σε...
by george14
[June 17, 2025, 13:58:20 pm]

Αποτελέσματα Εξεταστικής ...
by george14
[June 17, 2025, 12:08:25 pm]

[ΨEE] Γενικές απορίες και...
by Juror8
[June 17, 2025, 12:06:57 pm]

[Οργάνωση Υπολογιστών] Γε...
by RAFI
[June 16, 2025, 22:46:54 pm]

[Σ.Π.Η.Ε.] Γενικές απορίε...
by Nikos_313
[June 16, 2025, 19:49:00 pm]

[ΘΤΠΑ] Γενικές απορίες κα...
by Nikos_313
[June 16, 2025, 16:56:56 pm]

[Αρχές Οικονομίας] Να επι...
by _Trob
[June 16, 2025, 13:28:21 pm]

[Σ.Α.Π.Γ.] Εργασία 2025
by Nikos_313
[June 16, 2025, 12:13:45 pm]
Στατιστικά
Members
Total Members: 9965
Latest: Poli
Stats
Total Posts: 1426725
Total Topics: 31712
Online Today: 195
Online Ever: 2093
(April 17, 2025, 08:47:49 am)
Users Online
Users: 50
Guests: 133
Total: 183
hacky
amaliakon
iropap
arxigos18
giani10
vajim
Petross
pavlaras
Theosarm
Oxil
mike1996
tzortzis
victoria
Belafonte
Pastellaki
KZerenidis
kkon
Angelos Asim
HlektrikhPatata
vaggelis.ntokas
koulakidis
Marihouan820
agkentzi
ioathemar
gpr000
anastas1a
ioannisfa
mixkats
Antonistsak
lsim
rikos4
stmanzaf
stavrospk
myrtosa
Retroman07
Asozou
kourasan!
Fenia04
micelethe
gianniss
tsaliki
Vassoula
jimalexoud
Thanoskask
EvanTsir
Εμφάνιση

Νέα για πρωτοετείς
Είσαι πρωτοετής;... Καλώς ήρθες! Μπορείς να βρεις πληροφορίες εδώ. Βοήθεια για τους καινούργιους μέσω χάρτη.
Κατεβάστε εδώ το Android Application για εύκολη πρόσβαση στο forum.
Ανεβάζετε τα θέματα των εξετάσεων στον τομέα Downloads με προσοχή στα ονόματα των αρχείων!

Νέα!
Πρόγραμμα Χειμερινής Εξεταστικής 2024-2025
THMMY.gr > Forum > Μαθήματα Βασικού Κύκλου > 2ο Εξάμηνο > Αντικειμενοστραφής Προγραμματισμός (Moderators: chatzikys, tzortzis) > [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
0 Members and 1 Guest are viewing this topic.
Pages: 1 ... 3 4 [5] 6 Go Down Print
Author Topic: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014  (Read 11358 times)
L
WebSlave
Καταστραμμένος
***
Posts: 5562


Bad faith


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #60 on: January 26, 2014, 14:37:11 pm »

Quote from: PureForm on January 25, 2014, 12:04:44 pm
προσπαθησε να κανεις realloc με την new και την delete στην Κορτέσια C++ και θα καταλαβεις γιατι

fixed



Από Bjarne Stroustrup:

Why doesn't C++ have an equivalent to realloc()?

If you want to, you can of course use realloc(). However, realloc() is only guaranteed to work on arrays allocated by malloc() (and similar functions) containing objects without user-defined copy constructors. Also, please remember that contrary to naive expectations, realloc() occasionally does copy its argument array. In C++, a better way of dealing with reallocation is to use a standard library container, such as vector, and let it grow naturally.
Logged

It was the best of times, it was the worst of times, it was the age of wisdom, it was the age of foolishness, it was the epoch of belief, it was the epoch of incredulity, it was the season of Light, it was the season of Darkness, it was the spring of hope, it was the winter of despair, we had everything before us, we had nothing before us.

cdvasile
Καταξιωμένος/Καταξιωμένη
***
Gender: Male
Posts: 108



View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #61 on: January 26, 2014, 19:04:45 pm »

μπορει να εξηγησει καποιος πως λειτουργει στο 3ο 8εμα φλεβαρη του 13 το προγραμμα???
Logged
L
WebSlave
Καταστραμμένος
***
Posts: 5562


Bad faith


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #62 on: January 26, 2014, 20:07:02 pm »

Quote from: cdvasile on January 26, 2014, 19:04:45 pm
μπορει να εξηγησει καποιος πως λειτουργει στο 3ο 8εμα φλεβαρη του 13 το προγραμμα???

Υποθέτοντας ότι σε μπερδεύει το

Code:
operator int() {return y%x;}

, αυτό κάνει το εξής:

Στα

Code:
p[0].fun()->x=*(p[1].fun())+p[2];
p[0].fun()[0].y=p[1]*p[2];

αριστερά έχεις μία μεταβλητή τύπου int. Στα δεξιά, για να μπορέσει να γίνει πράξη, θα γίνει αυτόματα cast σε int, οπότε όπου p[1] και p[2] θα μπουν τα αντίστοιχα y%x τους.
« Last Edit: January 26, 2014, 20:10:54 pm by L » Logged

It was the best of times, it was the worst of times, it was the age of wisdom, it was the age of foolishness, it was the epoch of belief, it was the epoch of incredulity, it was the season of Light, it was the season of Darkness, it was the spring of hope, it was the winter of despair, we had everything before us, we had nothing before us.

cdvasile
Καταξιωμένος/Καταξιωμένη
***
Gender: Male
Posts: 108



View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #63 on: January 26, 2014, 20:54:52 pm »

Quote from: L on January 26, 2014, 20:07:02 pm
Quote from: cdvasile on January 26, 2014, 19:04:45 pm
μπορει να εξηγησει καποιος πως λειτουργει στο 3ο 8εμα φλεβαρη του 13 το προγραμμα???

Υποθέτοντας ότι σε μπερδεύει το

Code:
operator int() {return y%x;}

, αυτό κάνει το εξής:

Στα

Code:
p[0].fun()->x=*(p[1].fun())+p[2];
p[0].fun()[0].y=p[1]*p[2];

αριστερά έχεις μία μεταβλητή τύπου int. Στα δεξιά, για να μπορέσει να γίνει πράξη, θα γίνει αυτόματα cast σε int, οπότε όπου p[1] και p[2] θα μπουν τα αντίστοιχα y%x τους.

ευχαριστω με εσωσες...
Logged
4emonas
Μόνιμος κάτοικος ΤΗΜΜΥ.gr
******
Posts: 1820



View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #64 on: January 27, 2014, 18:31:11 pm »

τι ακριβως κανει το return this?????
Logged

Ragnar Lothbrok
Εθισμένος στο ΤΗΜΜΥ.gr
*****
Gender: Male
Posts: 736


Hail King Ragnar!


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #65 on: January 27, 2014, 18:45:59 pm »

Αν εννοείς το return *this , επιστρέφει έναν pointer στο αντικείμενο που κάλεσε την συνάρτηση που περιείχε το this. Αν είπα κάτι λάθος διορθώσετε με
Logged

It gladdens me to know that Odin prepares for a feast.Soon I shall be drinking ale from curved horns. This hero that comes into Valhalla does not lament his death! I shall not enter Odin's hall with fear. There I shall wait for
my sons to join me, and when they do, I will bask in their tales of triumph. The Aesir will welcome me! My death comes without apology! And I welcome the valkyries to summon me home!

Ragnar's last speech
L
WebSlave
Καταστραμμένος
***
Posts: 5562


Bad faith


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #66 on: January 27, 2014, 18:59:24 pm »

Αν κάνεις return *this; σου επιστρέφεται το αντικείμενο. Αν κάνεις return this; σου επιστρέφεται η διεύθυνσή του.
« Last Edit: January 27, 2014, 19:03:14 pm by L » Logged

It was the best of times, it was the worst of times, it was the age of wisdom, it was the age of foolishness, it was the epoch of belief, it was the epoch of incredulity, it was the season of Light, it was the season of Darkness, it was the spring of hope, it was the winter of despair, we had everything before us, we had nothing before us.

απλυτος
Μόνιμος κάτοικος ΤΗΜΜΥ.gr
******
Posts: 1317



View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #67 on: January 27, 2014, 21:05:52 pm »

Οι template συναρτήσεις και κλάσεις ανήκουν στη σφαίρα της μεταγλώττισης ή της εκτέλεσης; αν έχω πάρει κάβο στης μεταγλώττισης.
« Last Edit: January 27, 2014, 21:08:25 pm by απλυτος » Logged

http://arage-e-a-a-k.blogspot.gr/
4emonas
Μόνιμος κάτοικος ΤΗΜΜΥ.gr
******
Posts: 1820



View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #68 on: January 27, 2014, 21:54:20 pm »

για template ειπε τπτ??? εννοω αν σκοπευει να βαλει... γτ στη c ειχε πει πως θα βαλει αρχεια τον ιουνη...
Logged

sk0uf
Ανερχόμενος/Ανερχόμενη
**
Posts: 88


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #69 on: January 27, 2014, 22:59:20 pm »

Είμαστε 100% σίγουροι ότι επιτρέπονται σημειώσεις;
Logged
Ragnar Lothbrok
Εθισμένος στο ΤΗΜΜΥ.gr
*****
Gender: Male
Posts: 736


Hail King Ragnar!


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #70 on: January 27, 2014, 23:03:41 pm »

Αύριο στις 12 γράφουμε έτσι;
Logged

It gladdens me to know that Odin prepares for a feast.Soon I shall be drinking ale from curved horns. This hero that comes into Valhalla does not lament his death! I shall not enter Odin's hall with fear. There I shall wait for
my sons to join me, and when they do, I will bask in their tales of triumph. The Aesir will welcome me! My death comes without apology! And I welcome the valkyries to summon me home!

Ragnar's last speech
Ragnar Lothbrok
Εθισμένος στο ΤΗΜΜΥ.gr
*****
Gender: Male
Posts: 736


Hail King Ragnar!


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #71 on: January 27, 2014, 23:04:44 pm »

Α και πόση ώρα έχουμε στη διάθεση μας στην εξέταση;
Logged

It gladdens me to know that Odin prepares for a feast.Soon I shall be drinking ale from curved horns. This hero that comes into Valhalla does not lament his death! I shall not enter Odin's hall with fear. There I shall wait for
my sons to join me, and when they do, I will bask in their tales of triumph. The Aesir will welcome me! My death comes without apology! And I welcome the valkyries to summon me home!

Ragnar's last speech
vasilis94
Veteran
Μόνιμος κάτοικος ΤΗΜΜΥ.gr
******
Gender: Male
Posts: 1511



View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #72 on: January 27, 2014, 23:06:00 pm »

Quote from: vashmmy on January 27, 2014, 23:03:41 pm
Αύριο στις 12 γράφουμε έτσι;

Ναι? Το πρόγραμμα αυτό λέει Tongue

Quote from: vashmmy on January 27, 2014, 23:04:44 pm
Α και πόση ώρα έχουμε στη διάθεση μας στην εξέταση;

2,5 ώρες είχαν πει στο μάθημα.

Quote from: sk0uf on January 27, 2014, 22:59:20 pm
Είμαστε 100% σίγουροι ότι επιτρέπονται σημειώσεις;

Ναι.. Το πε ο Συμεωνίδης και ό,τι άλλο τυπωμένο θέλεις, ακόμη και το βιβλίο του Εύδοξου (δεν είμαι σίγουρος για άλλα..)
Logged
Ragnar Lothbrok
Εθισμένος στο ΤΗΜΜΥ.gr
*****
Gender: Male
Posts: 736


Hail King Ragnar!


View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #73 on: January 27, 2014, 23:08:57 pm »

Πως κάνουμε αναζήτησή μέσα σε ένα αρχείο; Πέρα από το ανοίξουμε ένα κανάλι για το αρχείο. Μετά πως γίνεται η αναζηση;
Logged

It gladdens me to know that Odin prepares for a feast.Soon I shall be drinking ale from curved horns. This hero that comes into Valhalla does not lament his death! I shall not enter Odin's hall with fear. There I shall wait for
my sons to join me, and when they do, I will bask in their tales of triumph. The Aesir will welcome me! My death comes without apology! And I welcome the valkyries to summon me home!

Ragnar's last speech
vasilis94
Veteran
Μόνιμος κάτοικος ΤΗΜΜΥ.gr
******
Gender: Male
Posts: 1511



View Profile
Re: [Προγραμματιστικές Τεχνικές] Γενικές απορίες ανακοινώσεις/επικαιρότητα 2013/2014
« Reply #74 on: January 28, 2014, 00:06:15 am »

Quote from: vashmmy on January 27, 2014, 23:08:57 pm
Πως κάνουμε αναζήτησή μέσα σε ένα αρχείο; Πέρα από το ανοίξουμε ένα κανάλι για το αρχείο. Μετά πως γίνεται η αναζηση;

Μπορείς να χρησιμοποιήσεις κατευθείαν το όνομα του καναλιού για να πάρεις τιμή για κάποια μεταβλητή (πχ. string) για την οποία ψάχνεις.

Θα χρησιμοποιήσεις και μια while που θα σταματά όταν φτάσει στο τέλος και όλα μια χαρά.

Τσέκαρε αυτό από το 11.08 και έπειτα: http://www.youtube.com/watch?v=may3eQaf40s
Γενικά σίγουρα υπάρχουν καλύτερα tutorials, αλλά για παράδειγμα, αν αντί για τη μετατροπή που κάνει εκεί, βάλεις το στοιχείο που κάνεις search και ένα μήνυμα το βρήκε, είναι αυτό που θες.
Logged
Pages: 1 ... 3 4 [5] 6 Go Up Print
Jump to:  

Powered by SMF | SMF © 2006-2009, Simple Machines LLC
Scribbles2 | TinyPortal © Bloc | XHTML | CSS
Loading...