Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

Implement the following sequence of operations one by one

1. Make a linked list for 26 (a to z) English alphabets where each node consists a single alphabet, an integer data for frequency count (initially 0) and next pointer. This list should be sorted in ascending order according to the ASCII value of the alphabets.

2. Now you have given a string consists of English alphabets. Your task is to update the frequency count values of above list for each occurrence of alphabets inside the given string.

For example, if the string is “babaaedd” then the updated list should be like this:

3. Finally traverse the whole list and print each Alphbets with their frequency one by one from a to z. Please follow the sample input-output format. Input string length is not more than 100.

Sample Input:

Mistcsedepartment


Sample Output:

a : 1

b : 0

c : 1

d : 1

e : 3

f : 0

g : 0

h : 0

i : 1

j : 0

k : 0

l : 0

m : 2

n : 1

o : 0

p : 1

q : 0

r : 1

s : 2

t : 3

u : 0

v : 0

w : 0

x : 0

y : 0

z : 0


Input: aabbhayy

Output: A2B2H1A1Y2

Note : please solve the above coding problem in python.



Given an integer

N as a starting number and K as input, write a program to print a number pyramid of K rows as shown below.Input

The first line of input is an integer

N. The second line of input is an integer K.Explanation

In the example, the given starting number is

10, and the number of rows in the pyramid is 5.


Write C++ program to print pyramid using *.

     

    *

   * * *

  * * * * *

 * * * * * * *

* * * * * * * * *



Write a menu driven single program, using switch case to perform the following operations in a single linked list by using different suitable user defined functions for each case.

[Ask the user "Do you want to continue (Press 1 or 0)"]


Traverse the list

Check if the list is empty [Call this to check underflow condition during the delete operation]

Insert a node after a given data item

Insert a node before a given data item

Delete a node after a given data item

Delete a node before a given data item

Insert a node at the certain position (at beginning/end/any position)

Delete a node at the certain position (at beginning/end/any position)

Delete a node for the given key

Search for an element in the linked list

Sort the elements of the linked list

Print the elements of the linked list in the reverse order

Reverse the nodes of the linked list

Print nth node from the last of a linked list

Delete the duplicate elements in a linked list


There is a binary tree given to you. In which each of the node represents the student in the class.
You are playing a game in which you need to team up with one of student in class. Team can be
formed in such a way that in a team both of the students can’t have same parent in tree and should
be at the same level in binary tree.
Input: we have given you some pair of students you need to find that is the team valid or not.
Output: ‘Yes’ if the team is valid or ‘No’ if the team is invalid.
(a) Optimal solution of O(n) for checking the team validity.
(b) How many tree traversal is required for the solution of the above problem.
Marking Scheme: Total 15 marks-> 10 for part (a)( Algorithm explanation + Pseudo-code +
runtime and data structure used)+ 5 for part (b)(explanation is required)

(Tic-Tac-Toe) Create a class Tic-Tac-Toe that will enable you to write a program to play Tic-Tac-Toe. The 

class contains a private 3-by-3 two-dimensional array. Use an enumeration to represent the value in 

each cell of the array. The enumeration’s constants should be named X, O and EMPTY (for a position 

that does not contain an X or an O). The constructor should initialize the board elements to EMPTY. 

Allow two human players. Wherever the first player moves, place an X in the specified square, and place 

an O wherever the second player moves. Each move must be to an empty square. After each move, 

determine whether the game has been won and whether it’s a draw. Also, allow the player to specify 

whether he or she wants to go first or second.


x Number of players are participating in a sporting event.They are standing in a row.
Each player has some match value associated with them. Now each player wants to make one
friend on their right side having greater match value as compared to him and it should be the
nearest player as well to him.
Your task is to print for each player their friend’s index and his match value. If a player is not
able to make such a friend print -1.
a) Find an Algorithm of Complexity O(n^2) to solve this problem.
b) Find an efficient way to compute the friends in O(n) Complexity.
Assume 1-based indexing.
Two monkeys Charlie and Leo are standing at two different nodes of a tree.
This tree is very weird, its root is situated at the highest point and grows in a downward
direction.
Also it consists of several nodes and branches connecting two different nodes.But at max 2
branches can originate from a node.
Now ,there are some tasks which they have to perform using some algorithms.Since they are
very lazy they want you to complete those tasks.
Task 1:- They want to move to the root node.So they want to calculate the individual distance
each of them have to travel in reaching to the root.
Task2:-They want to meet with each other .So they want to compute the distance between each
other before they start moving.
Can you help them in achieving these tasks?
Assumption:- Assume Tree as binary Tree.
You will be given the root Node of the tree and the reference nodes containing the address of
the nodes where charlie and leo are present
Task1 and Task2 -(Algorithm Explanation+Pseudo code+Time Complexity)

Write a javascript program that asks the user to enter his or her first name and then last name, and then 

constructs, stores, and displays a third string consisting of the user’s last name followed by a comma, a 

space, and first name. Use string objects and methods from the string header file. A sample run could 

look like this:

Enter your first name: Paul

Enter your last name: Smith

Here’s the information in a single string: Smith, Paul


LATEST TUTORIALS
APPROVED BY CLIENTS