Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make a generic function for getting time and price #2

Open
xaabi6 opened this issue Apr 27, 2017 · 0 comments
Open

Make a generic function for getting time and price #2

xaabi6 opened this issue Apr 27, 2017 · 0 comments

Comments

@xaabi6
Copy link
Collaborator

xaabi6 commented Apr 27, 2017

We've got two functions under 'transform.clj', they are called 'makeSplitTiempo' and 'makeSplitPrecio'.

The first one gets the time and the other one the cost for that time. They both split the received string, however, one takes the part corresponding to the time and the other to the cost. So, we need to specify a number which takes care of selecting which part of the splitted string we want to get.

For example 'makeSplitPrecio' function looks like:

image

We need to replace the number the arrow is pointing to by a variable which value needs to change every time we call the function. In that way we'll ensure that we get all the splitted parts of the string and not just the first one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant