All Questions
Tagged with functional-programming scala
8
questions
6
votes
2answers
220 views
Improving my Tic Tac Toe Solution in Scala
I'm relatively new to Scala and made a small TicTacToe in a functional Style.
Any improvement options would be highly appreciated.
There are some things which I am unsure of if they are made in an ...
3
votes
1answer
149 views
Improvements, TicTacToe in Scala
I've just started my journey into functional programming and tried to implement a TicTacToe game Recursively without State in Scala.
What I dislike is the JOptionPane but I don't know if i can solve ...
3
votes
1answer
68 views
Efficiently calculate value of Pascal's Triangle using memoization and recursion
So reading about functional programming, applications to dynamic programming, and learning Scala. I figured I would try it out with a popular example, Pascal's Triangle, tests against known values ...
2
votes
4answers
5k views
Calculating a base price with surcharge conditions
The following code has a lot of conditionals. I am trying to write
it in a functional programming way.
...
1
vote
2answers
373 views
Print matrix in spiral order in Scala
Problem:
Given a square or rectangular matrix, print its element in spiral
order.
For example, if input matrix is this:
...
5
votes
2answers
309 views
Change code to use functional style
I tried to solve a programming contest problem in Scala, but I have a feeling, that it could be done in a more functional way. I compared it with the solution written in imperative style and it is not ...
0
votes
1answer
501 views
0
votes
0answers
48 views
Efficiently calculate value of Pascal's Triangle using memoization and recursion(updated)
Follow up to Efficiently calculate value of Pascal's Triangle using memoization and recursion
Based on feedback given by jvwh in the answers
...