Myanmar IT Resource Forum
Myanmar IT Resource Forum
Myanmar IT Resource Forum

You are not connected. Please login or register

View previous topic View next topic Go down  Message [Page 1 of 1]

C0D3R

C0D3R
MITR Master



MITR Master
ဒါေလးကေတာ႔ကၽြန္ေတာ္စမ္းထားတာပါ
C++ မွာ source file ကိုၾကိဳက္သလိုေရးလို႔ရလားဆိုတာပါပဲ႕ျပီးေတာ႔ဒါကို platform လို႔ေခၚတာလားဆိုတာကၽြန္ေတာ္နားမလည္လို႔ပါ
ေရးထားတာမတူေပမယ္႔ output ကအတူတူပဲ႔ျဖစ္ေနလို႔
#include
#include
#include
using namespace std;
int main()
{
printf("Example\n");
printf("sentence\n");
printf("to\n");
printf("test\n");
printf("isspace\n");
system("PAUSE");
return 0;
}
save it 1.cpp

ျပီးေတာ႔ ေနာက္တစ္မ်ိဳး
#include
#include
#include
using namespace std;
int main()
{
cout<<"Example"<
cout<<"sentence"<
cout<<"to"<
cout<<"test"<
cout<<"isspace"<
system("PAUSE");
return 0;
}
save it 2.cpp

ဒါကေတာ႔ စာေၾကာင္းရွည္ေတြကိုေရးရာမွာ ပိုေကာင္းပါတယ္
cout လို႔ခဏခဏေရးေနစရာမလိုေတာ႔ပါဘူး
space ခံထားတဲ႔ေနရာမွာေနာက္တစ္ေၾကာင္းဆင္းသြားတာပါ
#include
#include
#include
int main ()
{
int c;
int i=0;
char str[]="Example sentence to test isspace\n";
while (str[i])
{
c=str[i];
if (isspace(c)) c='\n';
putchar (c);
i++;
}
system("PAUSE");
return 0;
}

save it 3.cpp

http://www.myanmaritresource.info

Law Shay

Law Shay
VIP Member



VIP Member
ဒါကုိ Platform လုိ႕ မေခၚႏုိင္ပါ။ပထမ တစ္ပုဒ္က Standard C Library ကုိ သံုးၿပီး ေရးထားတာပါ။ (stdio)ဒုတိယ တစ္ပုဒ္က Standard C++ Library ကုိ သံုးၿပီး ေရးထားတာပါ။ (iostream)stream ေတြမွာ file, monitor, printer စသျဖင့္ stream အမ်ိဳးမ်ိဳး ရွိပါတယ္။တတိယ တစ္ပုဒ္ကေတာ့ ပုိၿပီး ေယဘူယ်က်တာေပါ့။Platform ဆုိတာကေတာ့ Hardware platform, Software platform.  ေဆာ့ဖ္၀ဲမွာမွ  OS platform, Library Platform အမ်ိဳးမ်ိဳး ကြဲပါတယ္။

C0D3R

C0D3R
MITR Master



MITR Master
အခုလို၀င္ေရာက္ရွင္းျပေပးတဲ႔အတြက္ေက်းဇူးပါ

ေနာက္လည္းရွင္းျပေပးပါဦးေနာ္အားကိုးပါတယ္

http://www.myanmaritresource.info

chan.virus

chan.virus
MITR Reader



MITR Reader
အ၇မ္းေကာင္းတယ္ဗ်ာ
က်ေနာ္ကြန္ပ်ဴတာတက္ေနေပမယ့္
နညး္နညး္ေတာင္မ်က္စိလည္သြားတယ္
တခ်ိဳ့ဟာေတြကိေတာ့သင္ေတာင္မသင္ရေသးဘူး [You must be registered and logged in to see this image.]

Sponsored content


View previous topic View next topic Back to top  Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum

 

Create a forum on Forumotion | ©phpBB | Free forum support | Report an abuse | Forumotion.com