MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: List: please HELP!!!!

  • To: mathgroup at smc.vnet.net
  • Subject: [mg46220] Re: List: please HELP!!!!
  • From: Bill Rowe <readnewsciv at earthlink.net>
  • Date: Thu, 12 Feb 2004 07:15:47 -0500 (EST)
  • Sender: owner-wri-mathgroup at wolfram.com

On 2/10/04 at 12:05 AM, sabrinacasagrande at hotmail.com (sabrina)
wrote:

>I have generated a list of random numbers, With the functions Take
>and Transpose I can obtain a singular value, but it remains in the
>brackets: for example {4.5567} and I can't use it to do, for
>example, 4.5567+2. Mathematica gives me 2+{4.5567}. How can I
>eliminate the brackets?? 

In[1]:=
x={4.5556};
2+First@x
2+x[[1]]
2+Part[x,1]
2+Last@x

Out[2]= 6.5556

Out[3]= 6.5556

Out[4]= 6.5556

Out[5]= 6.5556

Note, all of these get the same value since x is defined as a list with one element. In general, this won't be true.
--
To reply via email subtract one hundred and four


  • Prev by Date: Re: Re: Can't display Times font in Windows XP
  • Next by Date: nonlinear regression
  • Previous by thread: Notebook problem: Most of the keys are not working on SuSE
  • Next by thread: nonlinear regression