Answers for "what is a string"

C++
1

string

#include <iostream>
int main()
{
	using namespace std;

	char name[20];       //declaring string 'name'

	cin.getline(name, sizeof(name)); //taking string input
	cout << name << endl; //printing string
	return 0;
}
Posted by: Guest on April-20-2021
0

string

x = str("s1") # x will be 's1'

y = str(2)    # y will be '2'

z = str(3.0)  # z will be '3.0'
Posted by: Guest on July-30-2021
0

string

Input: strings: "XXXXZY", "XXY", "XXZ"
Output: XXXXZY is interleaved of XXY and XXZ
The string XXXXZY can be made by 
interleaving XXY and XXZ
String:    XXXXZY
String 1:    XX Y
String 2:  XX  Z

Input: strings: "XXY", "YX", "X"
Output: XXY is not interleaved of YX and X
XXY cannot be formed by interleaving YX and X.
The strings that can be formed are YXX and XYX
Posted by: Guest on September-18-2021
-1

string

char c[] = "c string";
Posted by: Guest on October-08-2021

Browse Popular Code Answers by Language