Also i forget to say that in 2D the rows and columns don't require to have the 
same length
thanks

Eng A.Mahmoud

                      [email protected]

                   

                      [email protected]

                      OR

          send your asks to 

                   [email protected]

                   http://sites.google.com/site/eng7amadaprogramming/

                   
http://tech.groups.yahoo.com/group/eng_7amada_for_programming_works/


--- On Mon, 5/11/09, Ahmed Mahmoud <[email protected]> wrote:

From: Ahmed Mahmoud <[email protected]>
Subject: Re: [c-prog] Difference b/w pointer to pointer and 2D arrays
To: [email protected]
Date: Monday, May 11, 2009, 7:26 AM

Hi,The difference between pointer to pointer and 2D Array is that:

First 2D Array:The 2d Array is used -often-for tables for ex:int A[3][2] this 
means that this has 3 rows and 2 coloum  you can imagine that 

second pointer to pointer:we know that the pointer is used to hold the address 
the pointer to pointer  is used to hold the address of another pointer 
ex:int**x;

Thanks

Eng A.Mahmoud

                      [email protected]

                     
 [email protected]

                      OR

          send your asks to 

                   [email protected]

                   http://sites.google.com/site/eng7amadaprogramming/

                   
http://tech.groups.yahoo.com/group/eng_7amada_for_programming_works/

--- On Mon, 5/11/09, Thomas Hruska <[email protected]> wrote:

From: Thomas Hruska
 <[email protected]>
Subject: Re: [c-prog] Difference b/w pointer to pointer and 2D arrays
To: [email protected]
Date: Monday, May 11, 2009, 6:23 AM











    
            
            


      
      amir.khalid@ ymail.com wrote:

> Any one please tell me what is the diff b/w pointer to pointer and 2D array.



A "2D array", from your perspective, is perhaps best viewed as a subset 

of a "pointer to pointer".  In a 2D array, all the rows/cols have the 

same length:



*****

*****

*****

*****

*****



With a "pointer to pointer", you can do:



*******

**

****

******

*



-- 

Thomas Hruska

CubicleSoft President

Ph: 517-803-4197



*NEW* MyTaskFocus 1.1

Get on task.  Stay on task.



http://www.CubicleS oft.com/MyTaskFo cus/




 

      

    
    
        
         
        
        








        


        
        




      


      

[Non-text portions of this message have been removed]

Reply via email to