#include
#include
int main()
{
int i, j;
char str[10][50], temp[50];
printf("Enter 10 words:\n");
for(i=0; i<10; ++i)
scanf("%s[^\n]",str[i]);
for(i=0; i<9; ++i)
for(j=i+1; j<10 ; ++j)
{
if(strcmp(str[i], str[j])>0)
{
strcpy(temp, str[i]);
strcpy(str[i], str[j]);
strcpy(str[j], temp);
}
}
printf("\nIn lexicographical order: \n");
for(i=0; i<10; ++i)
{
puts(str[i]);
}
return 0;
} https://www.jdoodle.com/embed/v0/c/gcc-5.3.0/6WK
NOTE: A newer version is been updated on the site ... visit here http://vastgk.blogspot.com/2017/07/download-code-blocks-1601-mingwsetup.html File Date Download from codeblocks-13.12-setup.exe 27 Dec 2013 BerliOS or Sourceforge.net codeblocks-13.12mingw-setup.exe 27 Dec 2013 BerliOS or Sourceforge.net codeblocks-13.12mingw-setup-TDM-GCC-481.exe 27 Dec 2013 BerliOS or Sourceforge.net NOTE : The codeblocks-13.12mingw-setup.exe file includes the GCC compiler and GDB debugger from TDM-GCC (version 4.7.1, 32 bit). The codeblocks-13.12mingw-setup-TDM-GCC-481.exe file includes the TDM-GCC compiler, version 4.8.1, 32 bit. While v4.7.1 is rock-solid (we use it to compile C::B), v4.8.1 is provided for convenience, there are some known bugs with this version related to the compilation of Code::Blocks itself. IF UNSURE, USE "codeblocks-13.12mingw-setup.exe"! \ Linux 32-bit: Dis...
Comments
Post a Comment
share your thoughts ....