Results 1 to 25 of 30
Thread: 5 , ,
Hybrid View
-
4th August 2011 22:41 #1
5 , ,
- , .
1) ,
2) , ( -, -... you know).
:
: C++
- "int func(int a, int b, int c, int d)", "int func(int a, b, c, d)". - .
- min(), max(), sum() abs() ( , - - abs() - , ). min(), max() sum() - ( , inline-), n , , . :
. , func(a, from, to) ( , ).Code:int a[5] = { 1, 2, 3, 4, 5 }; cout << sum(a) << endl; // 15 cout << sum(a, 1) << endl; // [1] , 14 cout << sum(a, 1, 3) << endl; // 5 (a[1] + a[2]) cout << sum(a, 0, -1) << endl; // 10 ( ) - sizeof() . ,
Code:#if sizeof(long double) == 8 ... #else ... #endif
Code:struct SomeStructImGoingToSendAcrossTheNetwork {...}; #if sizeof(SomeStructImGoingToSendAcrossTheNetwork) != 68 # error Your compiler has some strange views on padding... #endif - newa[]. new[]<->malloc(), newa[]<->alloca(). ( alloca() + cast + for placement new- ). - alloca(). C++ 15+ , alloca().
4 , , (, regex-) C++1x.
. , C++ rant -
, . .
"640K ught to be enough for anybody" - Bill Gates, 1981
::Machine specs::Fract::AGG::::Baileys::blog::YouTube channel
-
5th August 2011 05:41 #2Registered User
Join Date: Aug:2008
Location: Varna
Posts: 291
1 . . . . 50/50
. jscript html. , , , , .
(memcpy, memxchg, memmove). .
sizeof. . sizeof. () . SOA AOS . , . .
. . device, . .
. .
-
5th August 2011 08:33 #3
int . int8_t, int16_t, int32_t, int64_t, int128_t . 0 runtime, . , .
Have no fear ike iz here.
CPU Cx486DLC@40MHz, RAM 4MB, VGA Trident 512KB, HDD Conner 160MB, Monitor 14" Color
-
5th August 2011 08:57 #4
-
5th August 2011 11:19 #5, . .
"640K ught to be enough for anybody" - Bill Gates, 1981
::Machine specs::Fract::AGG::::Baileys::blog::YouTube channel
-
5th August 2011 11:33 #6Hey, mother, I come bearing a gift. I'll give you a hint. It's in my diaper and it's not a toaster.
.
-
5th August 2011 13:19 #7Registered User
Join Date: Dec:2003
Posts: 2,817
php : - $object->method()[2]

, 5.4
Last edited by zlozi; 5th August 2011 at 16:41.
Gigabyte DS3P, E4400@9x333, 2x2Gb Super T@1000Mhz, Gigabyte GTX460OC 768Mb
-
5th August 2011 13:29 #8
.. -:
$object->method(2);
:
, .Code:public function method($id = null) { $arr = array(...); return ($id !== null) ? $arr[$id] : $arr; }
- chain, -
:
Code:$object->method()->returnById(2); $object->method()->returnArray();
Hey, mother, I come bearing a gift. I'll give you a hint. It's in my diaper and it's not a toaster.
.
-
5th August 2011 20:23 #9
,
1 inline if ,
2 switch for the fancy of it
3 dict.key, dict['key']
4 ++ ++
5 length, range,
: if chovek e gladen qde : if gladen e chovek qde. , ...Code:>>> a = ['Mary', 'had', 'a', 'little', 'lamb'] >>> for i in range(len(a)): ... print i, a[i] ... 0 Mary 1 had 2 a 3 little 4 lamb
-
6th August 2011 23:38 #10
-
7th August 2011 00:32 #11
Guido.
, GIL.
, !
-
5th August 2011 21:44 #12
:
1. malloc(), . , free() ( ), .
2. - - #if, #for? , .
function pointer , "element123->function()" "element123->function(element123)". this pointer , statement- 2 . , "->".
3. char () , - :
char mystring[20];
........
mystring="Hello, World";
strcpy.
, .
4. , malloc free ( 1 - , pointer ). :
strlen(itoa(myint));
, (same as typedef struct { char str[10] }; array_10).
, 4 .. HWBG !
-
8th August 2011 02:51 #13, . .
"640K ught to be enough for anybody" - Bill Gates, 1981
::Machine specs::Fract::AGG::::Baileys::blog::YouTube channel
-
18th August 2011 15:32 #14
Join Date: Jun:2002
Location: 85435
Posts: 4,619
pain in the arse! (Java)
- 2D .X570 Aorus Elite || R5 3600x || NH-D14 || 32GB RAM || GTX1070Ti Ultra Silent || PCE-AC56 || 850 EVO+MP510+HDDs || SSR-650RT all in Dark Base 900 || EV2736W || G29 || Obutto Ozone+Sparco R333
-
18th August 2011 18:54 #15
@Satanail : swt swing ?
swt JFaces .
.We are drowning in information, but starving for knowledge and time!
-
20th August 2011 14:25 #16
C#

1 - case sensitive.
2 - - ()
3 - properties, this.
4 - windows api , LoadLibrary ..
5 - winforms tooltip, .
5
-----------------------
Delphi:

x+=y x=y=z ...
-
20th August 2011 23:40 #17
Join Date: Jun:2002
Location: 85435
Posts: 4,619
-
5th August 2011 21:47 #18
1, , HeapAlloc/HeapReAlloc malloc HeapSize. , , .
, , VirtualAlloc VirtualQuery.EVGA X299 FTW K|i9-7960X@4.7|4x8 Patriot Viper Steel 4000|GTX 1660 Ti|970 EVO 1 TB|Seasonic Focus GX-1000|Xigmatek Elysium|
Rampage IV Extreme BE|E5-1680v2@4.7|4x4 HyperX 1866|Cougar Aqua 240|GTX 1050 Ti|970 EVO 1/4 TB|CM 850 SilentPro|HAF-X|
-
7th August 2011 17:26 #19
ANSI C:
1. String - , .
2. .h .c .
3.
4. div mod / %
5. Native .
-
7th August 2011 18:56 #20Registered User
Join Date: Aug:2006
Location:
Posts: 4,052
. *char[] ?
. , object code.
? , ?
#define
- hashmap .. ?
--------- 18:56 --------- : 18:53 ---------
AS3:
* - error handling .
Java:
* - boilerplate! ( Rich Hickley clojure)
X86:
* quirks
-
7th August 2011 21:13 #21Registered User
Join Date: Nov:2005
Location:
Posts: 3,317
-
21st August 2011 23:55 #22
-
22nd August 2011 01:21 #23ASUS X570-P|R7 5800X3D@NH-U14S|2X16G DDR4 3200 Corsair VENGEANCE LPX|Samsung 980 PRO 1TB|Radeon RX 7900 XTX 24G|AOC CQ32G1|Corsair RM750x|CM 693
-
21st August 2011 11:05 #24Registered User
Join Date: Mar:2004
Location:
Posts: 3,748
. ?
- ? , Type arr[size]; ?newa[]. new[]<->malloc(), newa[]<->alloca(). ( alloca() + cast + for placement new- ). - alloca(). C++ 15+ , alloca().
alloca() .
Java:
1. Array-of-structures . Java array of references, - ( ).
2. . , , . , .
3. Generics , ArrayList , (Int/Char/Double/...)Array ( for (int x: intlist) {...}; for (Integer x: intlist) {...}; ).
100% Java C/C++. , JIT , . JIT- boxing/unboxing, , JRE, .
-
21st August 2011 15:54 #25
, , . ( , ,
).
, , GCC , , , . - , ,
, , - .
... ( Python, Java Brainfuck...) , . ... , , 2-3
, . .
"640K ught to be enough for anybody" - Bill Gates, 1981
::Machine specs::Fract::AGG::::Baileys::blog::YouTube channel




Reply With Quote

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