Explore topic-wise InterviewSolutions in .

This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.

1.

Write a program to print “LinkedIn” if a number is divisible by 4 and 6, Linked if it is divisible by 4 and “in” if it is divisible by 6.

Answer»

def print_linked_in(NUMBER):
if number%4 == 0 and number%6 == 0:
print("LINKEDIN")
ELIF number%4 == 0:
print("LINKED")
elif number%6 == 0:
print("in")

 

2.

What is the use of API in LinkedIn developer documents?

Answer»

The basic use of API in developer documents of LinkedIn is STATED below:

  • For SIGNING into external services by using Linkedin
  • To ADD items or new attributes to PROFILES of users
  • For sharing articles and items on the timeline of the user’s
3.

State some Applications of LinkedIn.

Answer»

Some Applications of LinkedIn are listed below:

  • It can be USED to build and enhance personal brand and goodwill
  • Locating and establishing expertise
  • Can be used for PROFESSIONAL networking
  • Can be used to send private or group email messages to contacts
  • Can be used to find jobs
  • For sourcing and hiring employees
  • For the purpose of blogging and updating
  • For JOINING the public groups and participating in them
  • To share the knowledge
  • To keep track of where the professional contacts that can currently work, this can be also used to replace BUSINESS CARDS
4.

Write a program to check the closest K nodes to target in BST?

Answer»

VECTOR closestKValues(TreeNode* root, double TARGET, int k) {
vector res;
INORDER(root, target, k, res);
return res;
}

void inorder(TreeNode *root, double target, int k, vector &res) {
if (!root) return;
inorder(root->left, target, k, res);
if (res.size() < k) res.push_back(root->val);
else if (ABS(root->val - target) < abs(res[0] - target)) {
res.erase(res.begin());
res.push_back(root->val);
} else return;
inorder(root->RIGHT, target, k, res);
}

 

5.

What do you know about the LinkedIn Influencers’ Program?

Answer»

The LinkedIn Influencers’ PROGRAM was launched in the YEAR 2012 in the month of October. This program features global leaders, these global leaders share their professional knowledge and INSIGHTS with the members of LinkedIn. By records, there are more than 750 influencers on the platform and approximately 74% of these influencers are MALE. The influencer program is invite-only and has leaders from various industries. People like Bill Gates are also one of their influencers.

6.

Explain the flowchart?

Answer»

The flowchart is a graphical or a pictorial representation of the ALGORITHM using different symbols, and shapes, plus arrows to demonstrate the process or one program. With the algorithms, one can understand any program easily. The major purpose of the flowchart is ANALYZING different processes. Various standard graphics can be applied in the flowchart as mentioned below:

7.

State the features of LinkedIn.

Answer»

There are many attractive and USEFUL features on LINKEDIN and they are updated time-to-time. The features of LinkedIn have played a very IMPORTANT role in its popularity. Some important features of LinkedIn are stated below:

  • Hiding Connections
  • Exporting Connections
  • Deleting, Managing and Editing Skills and Endorsements
  • Creating LinkedIn SHOWCASE Pages
  • Hiding USER identity when they view other profiles
  • Saving the searches
  • Adding media to user profiles
  • Sending messages without making a connection
8.

What is the difference between syntax and fatal errors?

Answer»

One error is some kind of mistake. One can say that an error is one condition of possessing incorrect or inaccurate knowledge. Or the error can be defined as an unexpected, or an invalid STATE of a program from which RECOVERY is not possible.

syntax errors

These parse errors or syntax errors occur when there is some syntax mistake in coding the script, and the output comes to be Parse errors or syntax errors. Such TYPES of errors stop the CONTINUOUS EXECUTION of the required script. There can be several reasons behind the occurrence of such errors in the PHP language. Some common reasons are mentioned below.

The common reason for syntax errors:

  • Unclosed quotes
  • Unclosed braces
  • Missing or Extra parentheses
  • Missing semicolon
Fatal Errors

These are caused if PHP is able to comprehend what the user has written, but, what the user is asking PHP to do simply can not be done. These Fatal errors end the continuous execution for the script. When the user tries to access functions that are not defined, then what is received as output is the fatal error.

9.

Write a program to find the square root of a number.

Answer»

INT sqrt(int x) {
if (x == 0)
RETURN x;
int left = 1, right = x;
while (TRUE) {
int mid = (left + right) / 2;
if (mid &GT; x / mid)
right = mid - 1;
else if (mid + 1 > x / (mid + 1)) //mid < x / mid
return mid;
else
left = mid + 1;
}
}

10.

What do you know about multi-threading?

Answer»

Multithreading is that Java feature, which enables CONCURRENT execution for two or more than two PARTS of one program for the maximum utilization of the CPU. Each and every single PART of one such program comes to be known as a thread. Thus, threads are the light-weight processes that too WITHIN one process.