Guest User

Untitled

a guest
Jan 13th, 2018
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.31 KB | None | 0 0
  1. void AddCharToBufor(char k, char *bufor)
  2. {
  3.     int l=CheckStringlength(bufor);
  4.     char newBufor[l+1];
  5.     for(int i=0; i<l;i++)
  6.     {  
  7.         if(i==(l-1))
  8.         newBufor[i]=k;
  9.         else
  10.         newBufor[i]=bufor[i];
  11.        
  12.  
  13.  
  14.     }
  15.     newBufor[l+1]='\0';
  16.     l=CheckStringlength(newBufor);
  17.     for(int i=0;i<l;i++)
  18.     {
  19.         bufor[i]=newBufor[i];
  20.     }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment