Change the line in word, it basically returns
Answer:
Let the function be Node* ins(Node *root,int k)
if root node is NULL then return new node with data equal to k.
If the k <root->data
root->left=ins(root->left,k);
else if k >root->data
root->right =ins(root->right,k);
At last return root.
Explanation:
Node is always inserted at the at the leaf node.We will search k in the tree if we hit a the leaf node the new node is inserted as the child of the leaf node.
Answer:
D) Unsupervised Data mining
Explanation:
Unsupervised data mining also refered to as undirected data mining reveals hidden patterns in unlabeled data. In this method, there are no output variables to predict. The aim of an unsupervised data mining technique is to uncover patterns in data based on the relationship between the data points and each other
The top-level domain is usually .com, .org, .net, and many more.
Answer:
#include <iostream>
using namespace std;
int main()
{
char str[100][20];
int n;
cout<<"Strings you want to enter"<<endl;
cin>>n;
cout<<"enter n strings"<<endl;
for(int i=0;i<n;i++)
cin>>str[i];
for(int i=0;i<n;i++)
{
if((int)str[i][0]==98) //ascii value b is 98
cout<<str[i]<<endl;
}
return 0;
}
Explanation:
The above written code is for printing the strings which starts with the letter b.
To check if the string starts with a letter b we are checking the ascii value 98 which corresponds to b and then printing those strings.