JAVA EXERCISES How to pass array as a function parameter

Опубликовано: 19 Февраль 2016
на канале: SIMPLECODE
235
1

Another java exercise I`ve done recently. The idea is kinda same as was in my other Python version - to pass functions as parameters. So I don`t really know how to pass functions list in java for now, but in this video we`ll pass an array of 0 and 1. If we encounter 0 - we apply increment function, then if we see 1 - apply square function. And function will return the result. For example if we pass an array [0, 1] and number 4, we`ll get this computation: 4 + 1 = 5; 5 * 5 = 25. To determine what function to use we`ll utilize a Switch statement. Hope this will be helpful to someone.
=====================================
SUBSCRIBE FOR MORE:
http://www.youtube.com/subscription_c...
=====================================


Смотрите видео JAVA EXERCISES How to pass array as a function parameter онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь SIMPLECODE 19 Февраль 2016, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 235 раз и оно понравилось 1 людям.