Search found 7 matches

by davidush
29 Jun 2016, 15:04
Forum: Limbajul C++
Topic: [clase]
Replies: 0
Views: 4668

[clase]

[*]Header #define AUTOTURISM #include <iostream> #include <string> #include <cstdlib> using namespace std; class Motor { public: bool pornit; void start(); void stop(); }; class Electromotor { public: void start(Motor&); }; class SistemPornire { Motor m; Electromotor e; public: SistemPornire (){} vo...
by davidush
29 Jun 2016, 14:57
Forum: Limbajul C++
Topic: Problema C++
Replies: 1
Views: 4291

Re: Problema C++

prin mostenire si faci o funtie virtuala care sa poate fi apelate de ambele clase care sa iti indice masina soferului, daca vrei un exemplu lasa-mi mesaj
by davidush
07 Jun 2016, 23:50
Forum: Limbajul C++
Topic: Constructor
Replies: 2
Views: 8678

Re: Constructor

nu ai constructorul implicit defineste-l in clasa si iti va rula :) daca vrei poti face si set la x si y pentru a pune ce valoare vrei tu
by davidush
21 Feb 2016, 03:20
Forum: Programare generala
Topic: ASEMBLER probleme
Replies: 0
Views: 4589

ASEMBLER probleme

#include "stdafx.h" #include <iostream> using namespace std; void GetNumberOfZeroAndOne(unsigned int n, unsigned int *z, unsigned int *o) { _asm { mov eax, [ebp + 8]; mov esi, 0; // numar zerouri mov edi, 0; // numar unu mov ebx, 2; start_while: cmp eax, 0; je exit_while; mov edx, 0; div ebx; cmp e...
by davidush
21 Feb 2016, 03:15
Forum: Limbajul C++
Topic: probleme rezolvate siruri de caractère
Replies: 0
Views: 3908

probleme rezolvate siruri de caractère

// // main.cpp // siruri de caractere // // Created by motas david on 26.11.2015. // Copyright © 2015 motas david. All rights reserved. // #ifdef _MSC_VER #define _CRT_SECURE_NO_WARNINGS #endif #include <iostream> #include <cstring> #include <fstream> using namespace std; ifstream fin("date.in"); o...
by davidush
20 Feb 2016, 17:01
Forum: Limbajul C++
Topic: Tic Tac Toe in C++
Replies: 1
Views: 5451

Re: Tic Tac Toe in C++

poate te ajuta ce am ... e un x si o co VS player si PLAYER VS PLAYER ai meniu facut sper sa iti fie util #include <iostream> #include "stdlib.h" using namespace std; int main() { int i, j, k = 0; char a[3][3], nume1[30], nume2[30], q, v; begin: char castig='r'; system("color A"); cout<< "jucatorul ...
by davidush
12 Jan 2016, 23:34
Forum: Limbajul C++
Topic: Eroare de program x si 0
Replies: 1
Views: 5167

Re: Eroare de program x si 0

cum e declarata matricea ca un vector? trebuie resetata matricea la sfarsit sa fie vida.. in rest super bun programul good job :whorship: