Sunday, January 1, 2017

REVERSING A KNOWN STRING without using STACK

Hello code lovers !                                Happy New Year 2017 !            
//REVERSING A KNOWN STRING
#include<stdio.h>
int main()
{
    char c[]="Ashutosh_Kumar_Singh";
    for(int i=(sizeof(c)-1);i>=0;i--)
    {
        printf("%c",c[i]);
    }
return 0;
}

No comments:

Post a Comment

Python script to show Laptop Battery Percentage

Source:  https://www.geeksforgeeks.org/python-script-to-show-laptop-battery-percentage/ # python script showing battery details  import psut...