मैं इस समारोहडिफ़ॉल्ट और वैकल्पिक तर्क कैसे हैं?
def start(data, opts \\ [pages: 17, depth: 3]) do
maxPages = opts[:pages]
maxDepth = opts[:depth]
IO.puts maxPages
IO.puts maxDepth
end
जब मैं Program.start("data", pages: 8)
तो मैं इसे 8
और 3
प्रिंट करना चाहते है, लेकिन यह केवल प्रिंट 8