/* Collection of code snippets by Arne Vajhøj */
/* (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) */
#include <stdio.h>
#include <string.h>

int main()
{
    int i;
    char s[255];
    printf("Enter string: ");
    fgets(s, sizeof(s), stdin);
    for(i = 0; i < strlen(s); i++)
    {
        printf("%c", s[strlen(s) - 1 - i]);
    }
    printf("\n");
    return 0;
}
