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

Wedding game

In a wedding that you are attending, there are some chairs that have digits inscribed at their
backs. The chairs are lined in a row such that they form a string of the digits. Find the
minimum number of sets M that can be formed from these digits such that:
1. The number of digits in each set is one gf more than one.
2. Each set is formed using consecutive digits and no digit can be used more than once.
3. In each set, the number formed using the digits is less than or equal to Y.​
Addition number

Victor has an array of size n. He loves to play with these n numbers. Each time he plays
with them, he picks up any two consecutive numbers and adds them. On adding both the
numbers, it costs him k*(sum of both numbers).
Find the minimum cost of adding all the numbers in the array.
Input Specification:
input1: Size of array.
input2: Elements of the array.
input3: Value of k.
Output Specification:
Return the minimum cost of adding all the numbers of the array.
Charles and the Necklace
Charles wants to buy a necklace in which.
1. There is a minimum of 1 pearl and maximum of X pearls, such that each
pearl has its own magnificent coefficient
2. The pearls should be in non-decreasing order of their magnificence power.
You are given the maximum number of pearls in a necklace and the range of
the magnificent coefficients of the pearls. Find the number of necklaces that
can be made that follow the mentioned conditions.​

Compute the value of AFD416-BECE16+67758 using signed magnitude representation


Question 1:

write a program to find the given string in the root directory that contains a text file

1. In a recursive manner (case in sensitive )

2. only in the root directory

use command line arguments.

program_name -ri string root_dir (recursive)

program_name -si string root_dir (root director )

The output which file and line contains the string


Question 1:

Finder program

# Dict, list, queue

# directory --- os.walk()

list1 = [c:, d:, e:]

dict1 = {}

def func(drive)

resp = os.walk(drive)

statem1

st

dict1[file] = path

for drive in list1:

#th1 = Thread(target= func(drive))

#th1.start()

func(drive)

# apply join

finding total time of execution #

dict ---> pickle


Question 1:

How to make object as callable video __call__

from collections import Counter

class MyCounter(Counter):

Add here required code so that we can give data to object like co1("intel")

co1 = MyCounter()

co1("intel")


In this task, you need to understand two algorithms which can be helpful, the Breadth￾First Search which utilizes the Queue data structure to find the shortest path and the 

Depth-First Search which can traverse a Stack data structures. 

Hint:

Develop a data structure similar to binary trees. Using a standard 8 X 8 chessboard, show 

the knight’s movements in a game. As you may know, a knight’s basic move in chess is 

two forward steps and one sidestep. Facing in any direction and given enough turns, it 

can move from any square on the board to any other square. 

If you want to know the simplest way your knight can move from one square (or node) to 

another in a two-dimensional setup, you will first have to build a function like the one 

below.

knight plays ([0,0], [1,2]) == [[0,0], [1,2]]

knight plays ([0,0], [3,3]) == [[0,0], [1,2], [3,3]]

knight plays ([3,3], [0,0]) == [[3,3], [1,2], [0,0]]


Find the length of the following strings

char str1[] = "I love C+++ Programming! ";

char str2[] = "This is so cool!";

char str3[] = "Good job learner!";

The output should be like the following format:

The length of str1 is __

The length of str2 is __

The length of str3 is __


Given

rows = 4

cols = 3

matrix = 1 2 3

4 5 6

7 8 9

10 11 12


output : 1 2 3 6 5 4 7 8 9 12 11 10


Explination : Every alternative row should be in reverse order.


LATEST TUTORIALS
APPROVED BY CLIENTS