Search
 
SCRIPT & CODE EXAMPLE
 

CPP

strcat without using built in function

#include "stdio.h"
void main()
{
    printf("Enter the strings");
    char a[100],b[100],c[100];
    scanf("%s%s",&a,&b);
    int k=0,q=0,l,i=0;
    for(i=0;a[i]!='';i++)
    {
        c[i]=a[i];
    }
    for(k=0;b[k]!='';k++)
    {}
    for(int j=1;j<=k;j++)
    {
        a[k+j]=c[j-1];
    }
    for(int j=0;j<k;j++)
    {
        q++;
        a[j]=b[j];
    }
    for(int p=0;p<=i+k;p++)
        printf("%c",a[p]);
Comment

PREVIOUS NEXT
Code Example
Cpp :: how to calculate polar coordinates in c++ 
Cpp :: collections c# vs c++ 
Cpp :: can you verify adsense no ssl certificate 
Cpp :: retourner pointeur de type qstringlist qt 
Cpp :: watermelon codeforces solution 
Cpp :: gl draw line rectangle 
Cpp :: c++ while loop decrement 
Cpp :: gestd::getline with wstring 
Cpp :: for loop reverse C++ 
Cpp :: google test assert eq float 
Cpp :: qt qimage load from file 
Cpp :: what is time complexity of min_element() 
Cpp :: c++ srand() 
Cpp :: dlopen failed: library "libomp.so" not found 
Cpp :: how to get a word from file c++ 
Cpp :: quick sort c++ 
Cpp :: qt double en qstring 
Cpp :: macro c++ 
Cpp :: Sort array using inbuilt sort function in decreasing order 
Cpp :: c++ area of triangle 
Cpp :: c++ fibonacci 
Cpp :: string input with space c++ stl 
Cpp :: reverse c++ string 
Cpp :: return by reference in cpp 
Cpp :: allow cross origin 
Cpp :: factorial in c++ 
Cpp :: split string on character vector C++ 
Cpp :: how print fload wiht 2 decimal in c++ 
Cpp :: c++ template example 
Cpp :: c++ cout colored output xcode 
ADD CONTENT
Topic
Content
Source link
Name
7+7 =