How a pointer variable declared in c, Computer Engineering

Assignment Help:

How a pointer variable declared in C ? Why is it sometimes desirable to pass a pointer to a function as an argument?

A pointer is a variable which contains the address in memory of another variable. We can have a pointer to any variable type.

To declare a pointer to a variable do:

int *ip;

This declaration looks like our earlier declarations, with one obvious difference: that asterisk. The asterisk means that ip, the variable we're declaring, is not of type int, but rather of type pointer-to-int. (Another way of looking at it is that *ip, which as we'll see is the value pointed to by ip, will be an int.)

The unary or monadic operator & gives the ''address of a variable''.

The indirection or dereference operator * gives the ''contents of an object pointed to by a pointer''.

 


Related Discussions:- How a pointer variable declared in c

Modified digital clock, can you deign the schematic of a modified digital c...

can you deign the schematic of a modified digital clock at the gate as well as the IC level and then construct the circuit, lab spec and industral spec?

Determine the indicator variables in a random forest, Given a dataset with ...

Given a dataset with 1000 rows and 25 predictors labeled x1, x2, ...,x25 to classify into two classes {a, b}. Consider the small random forest with 3 trees and one split in each tr

State the optimal route of node, State the optimal route of node Consid...

State the optimal route of node Consider the node i which has path length K+1, with the directly preceding node on the path being j. The distance to node i is w(j, i) plus the

Evaluate speed of disk drive, Q. Evaluate Speed of disk drive? Drive S...

Q. Evaluate Speed of disk drive? Drive Speed: Amount of information which can be transferred in or out of memory in a second is called as disk drive speed or data transfer ra

Define the bandwidth of a monitor, Q. Define the Bandwidth of a monitor? ...

Q. Define the Bandwidth of a monitor? Bandwidth is the amount of signal the monitor can handle and it is rated in MHz .This is the most usually quoted specification of a monito

Explain one two motion selector per subscriber, What is 1 00 line exchang...

What is 1 00 line exchange with one two-motion selector per subscriber. Design: In, Strowger switching system is designed by using one two-motion selector for all subscrib

Illustrate the table of types of serach engines, Illustrate the table of ty...

Illustrate the table of types of serach engines Type in: CIE and the search engine would return about 22 million hits Type in

Chains of inference, Chains of Inference: Now we have to look at how t...

Chains of Inference: Now we have to look at how to get an agent to prove a given theorem using various search strategies? Thus we have noted in previous lectures that, there i

Why schottky transistors preferred over other transistors , In digital ICs,...

In digital ICs, Schottky transistors are preferred over normal transistors because of their ? Ans. Lower  propagation  delay  in digital ICs, as  shottky  transistors  reduce

What is the meaining of action implementing instruction, Action implementin...

Action implementing instruction's meaning are a actually carried out by ? Ans. By instruction execution, the meaning of action implementing instruction is actually carried out.

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd