390 likes | 613 Views
C ?????????, ?????????1000 ?, ????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????Naba Barkakati ???Turbo C Bibble ??????????????, ?????????????????????????????????????????????????????. 1 0 - 1 ????. ?????????????????, ??????
E N D
1. ???? ????????, ??????????????, ???????????, ?????????, ????????, ??????????, ??????????, ?????????, ?????, ??????????????????, ????????????
????????????????????, ???????????????????, ?????????????????????????????, ???????, ??sin ?cos ?random ??????????????????, ?????????????, ?????????????????, ??????, ????????????
2. C++ ?????????, ?????????1000 ?, ????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????Naba Barkakati ???Turbo C++Bibble ??????????????, ???????????????????????????????????????
????
????
????
??
3. 1 0 - 1 ???? ?????????????????, ?????????????????????:
#include <math.h>
??????????:
7. ???? ???e=2.718 ?????
1. ?????????, ??????100 %, ??????, ????????2 ??
2. ?????????, ??????100 %, ??????, ????????2.613 ?
3. ?????????, ??????100 %, ??????, ????????2.714 ?
4. ?????????, ??????100 %, ??????, ????????2.718 ?
8. ??10-1a ????????????
9. ??10-1b ?????, ???????????:
????
10. ????
1. ???????, ????????abs ???
2. ??abs ?0 ???????, ??????9 ?, ????i ?4 ?-4 ???
3. ???j ?????, ?????i ????j=abs(i)+1, ???0 ??,????1?
4. Canvas ?????, ??TextOut ??????, ????Canvas->TextOut(x, y, ??), ???x ??????????????, y ??????????
11. ??10-1c ????, ?????:
????
1. ??abs ???0 ???????????9 ?, ????????4To -4 ?9 ??
2. ?????y ??????????
3. ?????x ??, ?????, ???:
4.?????????abs(i), ????????????????, ??x ???i, j ?????:
x ??=abs(i)+2(j+1)
12. ??10-1d ????????w?
????
1. ???w ???, ?????(6, 6) ?(8, 4) ?(10, 6) ??:
2. 3 ?????3 ?abs, ?????????:
y=a|x-6|+b|x-8|+c|x-10|+d
3. ?????(0, 0)?(6, 6)?(8, 10)?(10, 6), ????????????:
6a+8b+10c+d=0
2b+4c+d=6
2a+2c+d=10
4a+2b+4c+d=6
4. 4 ????, 4 ????
, ????(??Excel ??,
????Office XP????)
a=-1 ?b=1 ?c=-1 ?d=8
13. ??10-1e ??????sin ???
14. ??10-1f ????????????, ?????
15. 1 0 - 2 ???? ???C++ ??????Sring, ??????, ???????????????:
char s[4] ="Marg"; // ????
char *str="Tom"; // ????
??????, ???????, ??BCB ????????????, ????????????????????, ??????????, ???????????????
String s="Marg"
???????????????, ???????????, ?????????????
19. ??10-2a ????????????
20. ??10-2b ?????, ?????????:
21. ??????? ??strCopy ??????????, ?????????Timer ???OnTimer ??, ???????????????, ?????????
22. ??10-2c ??????, ???????????
23. ??10-2d ??????, ???????????
24. ??10-2e ??????, ???????????
25. ??? ????????A ?B ??????,?????, ?????????????(??????????????)????????????????A; ????, ????, ??B???????????6713, ??6731 ????2A2B, ??7851 ????0A2B ????????????????????????????????????
26. ??10-2f ?????, ????????????, ??????????????(???????????????)
27. ??10-2g ???, ???????????, ???????(????????????????)
??????????????:
1. ??1000 ?9999 ?????
2. ????????????, ??1001 ?3343 ??
3. ?????????, ????????, ???1023 ?(???????A ?B, ?????????1A2B)
4. ????????, ?????, ???1023 ????, ???1A2B???????(?????????)
5. ??3.?4. ????, ???????4A0B ???
28. 1 0 - 3 ???? ????????????????, ???????time_t, ?????????????????, ??????????t1 ????????
time_t t1;
???????????, ????time ????, ???:
time (&tl) ; //tl ?????, ??8-2 ?
???t1 ??????, ?????????ctime ????????String ??, ?????????????????????????????, ????10-3a ?
Label1->Caption=ctime (&tl) ;
29. ????????????????, ??????????????????????, ????localtime ?gmtime ??tm ?????, tm????, BCB ???????:
struct tm
{
int tm_sec; ?, ???0~59
int tm_min; ?, ???0~59
int tm_hour; ?, ???0~23
int tm_mday; ?, ???1~31
int tm_mon; ?, ???0~11
int tm_ year; ?, ???1900 ???
int tm_wday; ??, ???0~6, ????0
int tm_ yday; ???????, ??0~365, ??1 ?1 ??0
int tm_ isdst; ??, ???????????
}
?????????*m1 ???tm ??????
tm *ml;
??????t1 ??tm ??????
m l = l o c a l t i m e ( & t l ) ;
?
ml= g mtime ( & t l ) ;
30. ???????????, ??m1 ?????asctime ????String????????, ???:
La b e l 1 -> C a p t io n= a s c t i m e (ml ) ;
???????????????, ???????????, ???, ???????????:
Label1->Caption=IntToStr(ml.tm_mon); // ????
?BCB ???, ?????????(???m1 ?????), ?????????(.) ?????(->), ??????????, ?????????
La b e l 1 - > C a pt i o n = I nt T oS t r (ml - > t m _mo n ) ;
C++ ?????????????:
32. ??10-3a ??????, ???????
33. ??10-3b ?????, ??????????
34. ??10-3c ??localtime ?gmtime ?asctime ??????
35. ??? ???????????????, ???????????, ???????, ????????, ??????????????????????????, ????????????????
36. ??10-3d ???????
37. ?? ?????????, ??????????, ??????????, ??????????, ????, ??????, ?????????, ?????????
38. ??10-3e ????????
39. 1 0 - 4 ?? 1. ?????????(?????????), ?????:
(1) ???4 ????
(2) ??2 ?????, ???2 ?????, ??????????
(3) ???2 ???????, ??????, ???2 ??????
(4) ?????????, ?????????
(5) ?????, ????2 ??????????
2. ????????????????