All pastes #29047 Raw Edit

Someone

public c v1 · immutable
#29047 ·published 2005-11-17 18:57 UTC
rendered paste body
#include <string.h>#include <stdio.h>int main () {        char string[]="1234";        int size=strlen(string);        int i;        printf("size of %s is %d\n",string,size);        for (i=0; i<size; i++) {                printf("string[%d] is %c\t",i,string[i]);                string[size]=string[i];                printf("string[%d] is %c\t",size,string[size]);                string[i]=string[size-i];                printf("string[%d] is %c\t",i,string[i]);                string[size-i]=string[size];                printf("string[%d] is %c\n",size-i,string[size-i]);        }        string[size]=0;        printf("size of %s is %d\n",string,size);}