ÇÁ·Î±×·¡¹Ö

 3204, 151/161 ȸ¿ø°¡ÀÔ  ·Î±×ÀΠ 
   tegi83
   ¹®ÀÚ¿­ 3°³¸¦ ³ôÀº¼ø¼­´ë·Î ¿¬°áÇÏ´ÂÇÁ·Î±×·¥ÀÔ´Ï´Ù

http://www.hackerschool.org/HS_Boards/zboard.php?id=QNA_programming&no=2052 [º¹»ç]


#include<stdio.h>
#include<string.h>

void concat3(char*,char*,char*,char*);

int main(void)
{
        char str1[50];
        char str2[50];
        char str3[50];
        char constr[150];

        printf("3°³ÀÇ ¹®ÀÚ¿­ ÀÔ·Â:");
        scanf("%s,%s,%s",str1,str2,str3);

        concat3(str1,str2,str3,constr);
        puts(constr);
        return 0;
}

void concat3(char *str1,char *str2,char *str3,char *constr)
{
        if(strcmp(str1,str2)==1)
        {
                if(strcmp(str1,str3)==1)
                {
                        strcpy(constr,str1);
                        if(strcmp(str2,str3)==1)
                        {
                                strcat(constr,str2);
                                strcat(constr,str3);
                        }
                        else
                        {
                                strcat(constr,str3);
                                strcat(constr,str2);
                        }
                }
                else
                {
                        strcpy(constr,str3);
                        if(strcmp(str1,str2)==1){
                                strcat(constr,str1);
                                strcat(constr,str2);
                        }
                        else
                        {
                                strcat(constr,str2);
                                strcat(constr,str1);
                        }
                }
        }
        else
        {
                if(strcmp(str2,str3)==1)
                {
                        strcpy(constr,str2);
                        if(strcmp(str1,str3)==1)
                        {
                                strcat(constr,str1);
                                strcat(constr,str3);
                        }
                        else
                        {
                                strcat(constr,str3);
                                strcat(constr,str1);
                        }
                }
                else
                {
                        strcpy(constr,str3);
                        if(strcmp(str1,str2)==1)
                        {
                                strcat(constr,str1);
                                strcat(constr,str2);
                        }
                        else
                        {
                                strcat(constr,str2);
                                strcat(constr,str1);
                        }
                }
        }
}
¾Æ·¡´Â ¿ö´× À̶ߴµ¥ ¿Ö±×·±Áö;;
±×¸®°í Á¤»óÀûÀ¸·Î µÅÁö¸¦ ¾Ê³×¿ä;;
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(14) : warning C4996: 'scanf': This function or variable may be unsafe. Consider using scanf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\stdio.h(306) : see declaration of 'scanf'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(27) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(30) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(31) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(35) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(36) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(41) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(43) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(44) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(48) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(49) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(57) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(60) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(61) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(65) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(66) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(71) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(74) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(75) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(79) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>c:\documents and settings\soul\my documents\visual studio 2008\projects\ex1\ex1\ex1.c(80) : warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1>        c:\program files\microsoft visual studio 9.0\vc\include\string.h(79) : see declaration of 'strcat'
1>Build log was saved at "file://c:\Documents and Settings\Soul\My Documents\Visual Studio 2008\Projects\ex1\ex1\Debug\BuildLog.htm"
1>ex1 - 0 error(s), 21 warning(s)
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========

  Hit : 5498     Date : 2009/06/08 10:06



    
tegi83 Çì´õ ÆÄÀ϶§¹®¿¡ ±×·±°¡;; ÈÉ... 2009/06/08  
md.house ¿ö´×À» Àо¼¼¿ä.
warning C4996: 'strcat': This function or variable may be unsafe. Consider using strcat_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS.
2009/06/08  
tegi83 º¸¾È»óÀÇ ¹®Á¦¶§¹®¿¡ ¿ö´×ÀÌ ¶ß´Â°Ç ¾Ë¾Ñ´Âµ¥ ÄÚµùÀº Ʋ¸®Áö¾ÊÀº°Å°°Àºµ¥ ÇÁ·Î±×·¥ÀÌ ¿Ö¾ÈµÅ´ÂÁú ¸ô¶ó¼­ »ý°¢ÁßÀÔ´Ï´Ù.¤Ð¤Ð 2009/06/08  
tegi83 ¿¡±Ã ´©°¡Á» ¾Ë·ÁÁֽøé;; 2009/06/10  
tegi83 ÈÄ......½ºÄµÇÔ¼ö¿¡ ¿Ö ÄÞ¸¶¸¦ÇÞÁö ¤Ð¤Ð 2009/06/10  
204   °íµîÇлý ÇÁ·Î±×·¡¹Ö ´ëȸ°°Àº °Í ¾ø³ª¿ä?[3]     gkswls123
03/23 5262
203     [re] C¾ð¾î¿Í ¸®´ª½º Ã¥ Á» ÃßõÇØÁֽñæ...[1]     ¼ÒÀ¯
09/18 5281
202   ÀΰøÁö´É ÇÁ·Î±×·¥À» ¸¸µé±â À§ÇØ ¾î¶² Áغñ(?)°¡ ÇÊ¿äÇÑ°¡¿ä?[4]     ERIC910903
04/24 5282
201   ¾È³çÇϼ¼¿ä c¾ð¾î Ãʺ¸ÀÚ µµ¿òÁ» ÁÖ¼¼¿ä(2) [C¾ð¾î] [ÇØ°á¿Ï·á:sohun5013´Ô][3]     lawsoul
01/15 5302
200   ¿Â¶óÀÎ °ÔÀÓ ÇÁ¸®¼­¹öÀÇ ¿ø¸®´Â ¹«¾ùÀΰ¡¿ä?[9]     splo1208
09/20 5305
199   C++ ÇÁ·Î±×·¥ Ŭ·¡½º Áú¹®[2]     killer759
05/07 5321
198   Á¦°¡Á÷Á¢ ÆÐŶÀ» Á¶ÀÛÇØ º¸³»°í½Í½À´Ï´Ù[4]     ¿³Àå¼ö
01/20 5368
197     [re] C ¾ð¾î ¿¹Á¦ ¹®Á¦,[1]     TIM_Scutum
02/05 5375
196   C++ °ü¸® ÇÁ·Î±×·¥¿¡¼­ È­¸é¿¡ ¸Þ´º È£Ãâ½Ã ¹®Á¦Á¡...[3]     ksbgenius
05/20 5395
195   c¾ð¾î Ãʺ¸ Áú¹®ÀÌ¿ä....(void¿¡ ´ëÇؼ­..)[13]     badboy25
02/04 5396
194   C¾ð¾î ´ë¹®ÀÚ->¼Ò¹®ÀÚ ¹Ù²Ù´Â main ÇÔ¼öÀε¥..[3]     dodomania
01/15 5397
193   2Â÷¿ø ¹è¿­¿¡ ´ëÇؼ­[3]     3cushion
11/02 5404
192   C¾ð¾î ÇÁ·ÎÅäŸÀÔ¼±¾ð[7]     twt525
12/24 5408
191   ÆäÀÌÁö ·Îµù½Ã Áñ°Üã±â ÀÚµ¿À¸·Î Ãß°¡µÇ±âÁ» °¡¸£ÃÄ ÁÖ¼¼¿ä[2]     dnflwltj
09/06 5479
190     [re] crypt¶ó´Â ÇÔ¼ö´Â ¹º°¡¿ä?[1]     ChuRack
02/17 5484
  ¹®ÀÚ¿­ 3°³¸¦ ³ôÀº¼ø¼­´ë·Î ¿¬°áÇÏ´ÂÇÁ·Î±×·¥ÀÔ´Ï´Ù[5]     tegi83
06/08 5497
188   ¾Æ Á¤¸» ¸ð¸£°Ú³×¿ä ... °í¼ö´Ôµé µµ¿ÍÁÖ¼¼¿ä ¤Ð.¤Ð (JAVA ¼Ò½º)[3]     tlsdbcjs
03/27 5510
187   À±¼º¿ìÀÇ ¿­Ç÷°­ÀÇ cÇÁ·Î±×·¡¹Ö¿¡¼­ µµÀü!ÇÁ·Î±×·¡¹Ö1[1]     yj6393
07/24 5521
186   ÇÁ·Î½ÃÀú¿Í ÇÔ¼öÀÇ Â÷ÀÌ[2]     h@cking2013
07/30 5528
185     [re] c ¾ð¾î Çñ׷¡¹Ö Áú¹®¿ä!!! °í¼ö´Ôµé Á» ºÁÁÖ¼¼¿ä.¤Ð[1]     ±«µµ³ªÀÌÃ÷
02/08 5531
[1].. 151 [152][153][154][155][156][157][158][159][160]..[161]

Copyright 1999-2024 Zeroboard / skin by Hackerschool.org / Secure Patch by Hackerschool.org