This is an old revision of the document!


Coding Cheat Sheet

Length of a string:

C++:

 stringVar.length() 

Python:

 len(stringVar) 

Adding a character to a string: c++:

// Appending the string. 
init.append(add);
// concatenating the string. 
strcat(init, add);  
// Appending the string. 
init = init + add; 
  • coding_cheat_sheet.1589058798.txt.gz
  • Last modified: 2020/05/09 21:13
  • by paul