From: Christophe Raffalli <raffalli@univ-savoie.fr>
To: "altavillasalvatore@libero.it" <altavillasalvatore@libero.it>
Cc: caml-list <caml-list@inria.fr>
Subject: Re: [Caml-list] small exercise
Date: Fri, 29 Nov 2002 16:30:42 +0100 [thread overview]
Message-ID: <3DE78822.7020304@univ-savoie.fr> (raw)
In-Reply-To: <H6CFX2$DB3343D5BB847C637A82FD5C6BE8421E@libero.it>
altavillasalvatore@libero.it wrote:
> Hi all,
>
> I do not succeed to develop the following exercise:
> I have need of your aid.
>
>
>
> input: string "1.15.120.13.43.35.340.190.0"
>
> output: int array= [| 1; 15; 120; 13; 43; 35; 340; 190; 0; |]
>
> : string -> int array
>
>
> Regards.
I hope you are not a student trying to have his home work done by this
mailing list ?
Just a hint look at the documentation of the following functions:
module | function
------------------------------
str | split
list | map
pervasives | int_of_string
array | of_list
The answer fits on one (long) line.
--
Christophe Raffalli
Université de Savoie
Batiment Le Chablais, bureau 21
73376 Le Bourget-du-Lac Cedex
tél: (33) 4 79 75 81 03
fax: (33) 4 79 75 87 42
mail: Christophe.Raffalli@univ-savoie.fr
www: http://www.lama.univ-savoie.fr/~RAFFALLI
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
next prev parent reply other threads:[~2002-11-29 15:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-11-29 15:19 altavillasalvatore
2002-11-29 15:29 ` Xavier Leroy
2002-11-29 18:29 ` Pierre Weis
2002-11-29 15:30 ` Christophe Raffalli [this message]
2002-11-29 18:48 ` Pierre Weis
2002-11-29 15:32 ` Jean-Christophe Filliatre
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3DE78822.7020304@univ-savoie.fr \
--to=raffalli@univ-savoie.fr \
--cc=altavillasalvatore@libero.it \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox