[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Odd string/index problem
- Subject: Odd string/index problem
- From: wmc(at)bas.ac.uk
- Date: 13 Sep 2000 19:37:15 GMT
- Newsgroups: comp.lang.idl-pvwave
- User-Agent: tin/pre-1.4-981114 ("The Watchman") (UNIX) (OSF1/V4.0 (alpha))
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:21386
Can someone explain this to me:
wmc> a='stoat'
wmc> print,a([0]),'>'
stoat
>
wmc> print,a(0),'>'
stoat>
This irritation surfaced when I tried to do
i=where(strings eq somestring)
print,strings(i)
which needs to be
i=i[0]
print,strings(i)
but why?
-W.
--
William M Connolley | wmc@bas.ac.uk | http://www.nerc-bas.ac.uk/icd/wmc/
Climate Modeller, British Antarctic Survey | Disclaimer: I speak for myself