Obtaining values text file with delimited

I have a txt file with delimited as shown below.
log.txt
|0000|01042014|
|0001|Lucas|
|0005|street blabla|
|0100|21031992|

he has to show, as it is below.

creation date of the file: 01042014
name : Lucas
address : street blabla
date of birth : 21031992

please.

IO::foreach
String#split
Array#[]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs