initialization of elements

hello, can anyone do the following:

- Write a single statement that sets the element of t in row 1 and column 2 to zero.



- Write a series of statements that initialize each element of t to zero. Do not use a repition structure


thanks

Comments

  • : hello, can anyone do the following:
    :
    : - Write a single statement that sets the element of t in row 1 and column 2 to zero.

    t[1][2] = 0;

    :
    :
    :
    : - Write a series of statements that initialize each element of t to zero. Do not use a repition structure

    Taking a leap of faith that t is a 2D array, then

    t[nrows][ncols] = { { 0 } };

    :
    :
    : thanks
    :
  • : hello, can anyone do the following:
    :
    : - Write a single statement that sets the element of t in row 1 and column 2 to zero.
    :
    :
    :
    : - Write a series of statements that initialize each element of t to zero. Do not use a repition structure
    :
    :
    : thanks


    No, I don't know anyone here that can do that... So you better figure it out yourself so you can tell the rest of us...

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories