Ask Question, Ask an Expert

+1-415-315-9853

info@mywordsolution.com

Ask C/C++ Expert


Home >> C/C++

1)a) What do you mean by const keyword? Demonstrate with help of suitable ex

b) Given the following code fragment:

int ch = 20;
cout << ch << ++ ch << ch << “\n”;

(i) The output of code fragment.

(ii) What is the effect of replacing ++ ch with ch + 1?

2) In the following program, if value of N given by user is 20, what maximum and minimum value the program could probably show?

#include
#include
void main()
{
int N, Guessme;
randomize();
cin>>N;
Guessme = random(N-10) + 10 ;
cout<}

3) prepare down the name of the header files that is needed to perform the following program segment

void main()
{
int n;
cout<<"Enter a number";
cin>>n;
if(n==0)
exit(0);
cout<<"Square of n is "<}

4)a) What do you understand by an Array? How does it differ from normal variable? What are the different methods of initializing the array? With suitable ex, show how to input and output elements in an array. Design block diagrams wherever needed

b) prepare a program to interchange elements of a given array as given below

A = 10 13 24 65 17 38 19 after change it must be

A = 13 10 65 24 38 17 19

(adjacent element interchange , if odd numbers last element remains unchanged)

C/C++, Programming

  • Category:- C/C++
  • Reference No.:- M910502

Have any Question? 


Related Questions in C/C++

Cosci 21a programming assignmentpurpose experience with

COSCI 21a, Programming Assignment Purpose: Experience with some basic data structures, including circular queues, linked lists, hash tables, and specifically with pointers and the associated dynamic memory allocation. Pr ...

Projectdecision statementsdirections read carefully and

Project: Decision Statements Directions (Read CAREFULLY and follow COMPLETELY): - Create the following programs in C++ that perform the purpose described and show the sample output (with user input where applicable). - I ...

Assignmentobjectivespractice reading characters from a

Assignment Objectives Practice reading characters from a file Practice using command line input Practice using command-line redirection of files Practice implementing a double transposition ciphering algorithm Summary In ...

Write a c program that prompts the user to enter a line of

Write a C program that prompts the user to enter a line of text (up to 50 characters). It should then convert the text entered to uppercase letters and then to lowercase letters, and then to Sentence case. Your program s ...

Assignmentpart acomplete the following questionswrite c

Assignment Part A Complete the following questions: Write C++ code to open a document with the name Hello.txt, place the message "Hello, World!" in the document, and exit the document. Re open the file you closed, and re ...

Intro to programming in c programming assignmentassignment

Intro to Programming in C Programming Assignment Assignment purpose: User defined functions, pointers, Menu driven program A Company needs to create software for their new line of phone applications. Customers will have ...

Discussionobject-oriented design please respond to the

Discussion "Object-Oriented Design" Please respond to the following: • Suppose you were required to write a C++ program that captures and stores data about automobiles that a small dealership in your city sells. Consider ...

Write a program to draw a symmetric shape of your own using

Write a program to draw a symmetric shape of your own using C++ user-defined functions and arrays. The program should draw a shape in its original and opposite forms (black and white and then white and black). Please con ...

Write a c program that calculates and prints the average of

Write a C program that calculates and prints the average of two or more salaries entered by the user. The program should first prompt the user to enter the number of salaries to process (make sure: at least 2 salaries mu ...

Programming in cbubba tubs bbq rub is a company that makes

Programming in C++ Bubba Tub's BBQ Rub is a company that makes different BBQ dry rubs and sauces. They make each product when it is ordered with the freshest ingredients and sell it by the unit. A unit is 2 ounces of pro ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

WalMart Identification of theory and critical discussion

Drawing on the prescribed text and/or relevant academic literature, produce a paper which discusses the nature of group

Section onea in an atwood machine suppose two objects of

SECTION ONE (a) In an Atwood Machine, suppose two objects of unequal mass are hung vertically over a frictionless

Part 1you work in hr for a company that operates a factory

Part 1: You work in HR for a company that operates a factory manufacturing fiberglass. There are several hundred empl

Details on advanced accounting paperthis paper is intended

DETAILS ON ADVANCED ACCOUNTING PAPER This paper is intended for students to apply the theoretical knowledge around ac

Create a provider database and related reports and queries

Create a provider database and related reports and queries to capture contact information for potential PC component pro