Question: SET B 1 . Consider a List of integer places that is not empty and is referred to as inList. In accordance with the following
SET B
Consider a List of integer places that is not empty and is referred to as inList. In accordance with the following line of reasoning, determine and output outList:
Using the following principles, construct a sequence of numbers for each element in inarr, beginning with the one that is immediately to the left of the current element:
In the series, the current element is the number that comes first in the sequence.
Using the current number as a starting point, the following formula is used to generate the next number in the sequence:
o Divide the current number by two to determine the next number in the sequence, provided that the current number is even.
o For the next number in the sequence, if odd, multiply the current number by three and then add one. This will give you the next number in the sequence.
o Continue performing the processes outlined above until the number is produced.
Using C program, determine how many numbers are contained in each sequence that has been constructed. Next, add the appropriate identified counts to outList in the order that the elements appear in inList.
Sample Input
Sample Output
Explanation:
Input:
For : Sequence Total count
For : Sequence Total count
Therefore, outList
Let A and B are two unsorted arrays. Write a program to merge and sort the elements of the arrays
A file contains n employee records. Each record contains Employee Name, Number and designation level and cumulative point reward point Write a C program to read each record and check whether the designation level is between to and grade point if so write it into another file
A data base contains lot of multiple electrify bills. The information that are available in the invoice bill is Customer Name, Customer Id Units consumed Amount for the bill and bill number. Write a C program to display the detail of a bill in the prescribed format if the bill number is given as the input using the random accessing method
Note: Database is maintained in the form of files
Compute taxes for a given income with tax slab rates as follows...
slab :
slab :
slab :
slab : for each range of a given income, the tax rate is different
eg input: x
divisions are
calculation: of x: of
of x: of
of x: of
output:
Write a C program to create a structure book with members, book title, author, genre fiction comedy, thriller, etc publisher, number of pages and price. Create an array of book structures and initialize them using for loop. Display the book details like title, author genre and price of all the books as a menu, get the required book as option from the user, the number of books required and the customers name and print the bill for the same.
Write a C program to create a structure book with members, book title, author, genre fiction comedy, thriller, etc price and an inner structure that contains publisher, number of pages and year of publication as members. Create an array of book structures and initialize them using for loop. Display all the book details including title, author genre price, publisher, number of pages and year of publication of all the books as a menu. Get the required book as option from the user, the number of books required and the customers name and print the bill for the same.
Write a C program to create a structure Person with name, age, and status, where status is either student or employee and a member feature which is a union type. The union type feature has two structures as members namely employee structure with members experience and organization and student structure with members gpa and course. Create two variables of type Person one of each type employee and student in the main function, initialize the details and print the details of both the person types in a neat format.
Write a program to take the following strings in two dimensional array and print them in sorting order and take any name and find whether the name exists in the array or not using LINEAR SEARCH.
Strings: HARITHA"CHANDANA","JYOTHI","HARIKA";
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
