My Name Is Salman Masood , I am Computer Science &Amp; Maths Graduate from University of Karachi, Pakistan , Teaching Is My Passion and My Aim Is to Deliver All My Knowledge among Those Students Who Can'T Afford Tutors or Expensive Institute Fees. I Will Be Keep Sharing My All Knowledge and Information with You .... Remember Me in Your Prayers !
Tuesday, 9 January 2018
Learn C language Part 33 Reverse source string into Destination string
#include <stdio.h>
#include <conio.h>
main()
{
char c[50];
char d[50];
int l=0,i=0,h;
printf("Enter the string : ");
gets(c);
while(c[l]!='\0')
{
l++;
}
h=l;
h--;
for(i=0;i<l;i++)
{
d[h]=c[i];
h--;
}
d[l]='\0';
puts(d);
}
Learn C language Part 32 Compare String Program {Checking two input str...
#include <stdio.h>
#include <conio.h>
main()
{
char c[50];
char d[50];
int i=0,flag=0;
printf("Enter the 1st String : ");
gets(c);
printf("\nEnter the 2nd String : ");
gets(d);
while(c[i]!='\0')
{
if(c[i]!=d[i])
{
flag=1;
break;
}
i++;
}
if(flag==0)
{
printf("both strings are equal!");
}
else
{
printf("both strings are not equal!");
}
}
Subscribe to:
Posts (Atom)
Pass Dynamically Added Html Table Records List To Controller In Asp.net MVC
Controller Code: using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; using ...
-
Load event: pictureBox3.Image = Image .FromFile( @"C:\Users\salman\Documents\Visual Studio 2013\Projects\WindowsFormsApplication3\W...