In the documentation:
count(*p*, *itr*) → Integer

Count the number of elements in itr for which predicate p is true.

> x = count(c->(c=="A"), "ACTGA")
> print(x)
>
gives the string "ACTGA", when expected 2

Am I missing something, or is the documentation incorrect? 

Also, a quick side question: How does one determine a variable type?  
type(x) doesn't work...

Thanks so much for the help.

Using Julia 0.2.1

Windows 7/64bit

Pkg.status()
Required packages:
 - BinDeps                       0.2.14+            master
 - Clang                         0.0.1
 - DASSL                         0.0.3
 - IJulia                        0.1.12
 - ImageView                     0.0.22
 - MAT                           0.2.5
 - Match                         0.0.5
 - ODE                           0.1.1
 - PyPlot                        1.2.10
 - Sundials                      0.1.0
Additional packages:
 - Cairo                         0.2.15
 - Cartesian                     0.2.2
 - Color                         0.2.11
 - HDF5                          0.2.26
 - HTTPClient                    0.1.0
 - Images                        0.2.47
 - IniFile                       0.2.2
 - JSON                          0.3.7
 - LibCURL                       0.1.3
 - LibExpat                      0.0.4
 - Nettle                        0.1.3
 - Polynomial                    0.1.1
 - PyCall                        0.4.8
 - REPLCompletions               0.0.1
 - SIUnits                       0.0.2
 - TexExtensions                 0.0.1
 - Tk                            0.2.13
 - URIParser                     0.0.2
 - URLParse                      0.0.0
 - WinRPM                        0.1.2
 - Winston                       0.11.2
 - ZMQ                           0.1.13
 - Zlib                          0.1.5

Reply via email to