Results 1 to 25 of 30
Thread: C++
Hybrid View
-
15th October 2005 18:58 #1
C++
, C++, , ( B) - .
: , :
= 911
B = 86
: - A B
, :/ASRock P67 Extreme4 / i5-2500K / 32GB Geil Evo Leggera DDR3-1866 / MSI GTX 970 / Samsung 840 Evo 250GB / 1TB Samsung SpinPoint F3 / 60GB OCZ Vertex 2 / Corsair HX850i / Corsair 730GT Full Tower / Arctic Freezer 7 Pro Ver2 / LG 34UC79G-B 34"
-
15th October 2005 19:07 #2Registered User
Join Date: Jul:2004
Location:
Posts: 621
-
16th October 2005 15:14 #3
-
16th October 2005 15:52 #42 . , 1 C++, - ( , , ). , 2 :
Originally Posted by CodeWarrior
- =050 ( 0 ), 50, 40..Code:#include <iostream.h> void main() { int i,j,k,a,b; cout <<"Vuvedi stoinost na A:\n"; cin>>a; cout <<"Vuvedi stoinost na B:\n"; cin>>b; i=a;j=b; again: k=i % j; if(k==0)goto stop; else {i=j;j=k; goto again; } stop: cout <<"Nai-golemiqt obsht delitel na "<<a<<" i "<<b<<" e "<<j<<endl; i=a;j=b; do { k=i%j; if (k==0)break; i=j;j=k; }while (true); }ASRock P67 Extreme4 / i5-2500K / 32GB Geil Evo Leggera DDR3-1866 / MSI GTX 970 / Samsung 840 Evo 250GB / 1TB Samsung SpinPoint F3 / 60GB OCZ Vertex 2 / Corsair HX850i / Corsair 730GT Full Tower / Arctic Freezer 7 Pro Ver2 / LG 34UC79G-B 34"
-
16th October 2005 16:02 #5
Last edited by singularity; 12th April 2007 at 13:54. Reason:
ignore list:Java,velio,jaredharet,gochev.george,Nit rogeniumQuis custodiet ipsos custodes?
-
16th October 2005 16:34 #6
, , ... .
, , -, , ?
Code:#include<stdio.h> int gcd(int a, int b) { if (b == 0) return a; else return gcd(b, a % b); } int main(){ int x,y,result; printf("Chislo1? "); scanf("%i",&x); printf("Chislo2? "); scanf("%i",&y); printf("rezultatyt e %i \n",gcd(x,y)); return 0; }
, 1 ?
, ? , lvalue?
cin/cout /
Last edited by Annihilator; 16th October 2005 at 16:47.
-
16th October 2005 16:35 #7Registered User
Join Date: Jul:2004
Location:
Posts: 621
, goto
, . goto- ( 8-15, ) while-, - main().
, "050" 40?! , .. :
, .Code:int a = 050;
.. Annihilator, - '&'
..2. , .
..3. /off : lvalue ( ) , ... ...Last edited by DimKo; 16th October 2005 at 16:57.
-
30th October 2005 18:06 #8. , win2k ( -) goto-.
Originally Posted by singularity




Reply With Quote

Lenovo ThinkPad 15 IdeaPad 15
5th May 2023, 22:16 in