Questions: 5 831

Answers by our Experts: 5 728

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

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.


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.

write a python program to find modules , exponentiation , power.


a company is planning a big sale at which they will give their customers a special promotional discount. each customer that purchases a product from the company has a unique customer id numbered from 0 to n-1.

1.andy, the marketing head of the company, has selected bill amounts of the n customers for the promotional scheme. the discount will be given to the customers whose bill amounts are perfect squares. the customers may use this discount on a future purchase. write an algorithm to help andy find the number of customers that will be given discounts?


an ecommerce website wishes to find the lucky customer who will be eligible for full value cashback. for this purpose, a number n is fed to the system. it will return another number that is calculated by an algorithm. in an algorithm, a sequence is generated, in which each number is the sum of the two preceding numbers. initially, the sequence will have two 1's in it. the system will return the nth number from the generated sequence which is treated as the order id. the lucky customer will be the one who has placed that order. write an algorithm to help the website find the lucky customer.


an ecommerce company plans to give their customers a discount for the new year. the discount will be calculated on the basis of the bill amount is the product of the sum of all odd digits and the sum of even digits of the customer's total bill. if no odd-even digit is represented in the bill amount then 0 will be returned?


1.usernum=int(input())

2.user Numspuared= userNum +User Num

3.

4.print(userNumspuared, end=‘ ‘)


python implement data structures?


startmsg = "python"
endmsg = ""
for i in range(1,1+len(startmsg)):
  endmsg = startmsg[-i] + endmsg




There is a singly linked list represented by the following structure:
struct Node int data;
struct Node* next;
Implement the following function:
struct Node
DeleteNodes (struct Node* head);
The function accepts a pointer to the start of the linked list, 'head' argument. Delete all such nodes from the input list whose adjacent on the right side has greater value and return the modified linked list. Note: . Return null if the list is empty (Incase of python if the list is No return None). Do not create a new linked list, just modify the input linked list an . return it. Example: Input: head: 6->2->5->4->9->7->2>1>5->9 Output: 65-9->7->2->9 Explanation: Node '2' is deleted as '2' < '5' then '4' is deleted as '4' < '9' then '1' deleted as '1' < '5' then '5' is deleted as '5' < '9'. Sample Input head: 9- 5 - 6 - 2 -> 7 Sample Output​
LATEST TUTORIALS
APPROVED BY CLIENTS