Skip to content

Added thomas algorithm in kotlin #539

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

Merged
merged 3 commits into from
Nov 9, 2018
Merged

Added thomas algorithm in kotlin #539

merged 3 commits into from
Nov 9, 2018

Conversation

sklan
Copy link
Contributor

@sklan sklan commented Oct 30, 2018

No description provided.

@berquist berquist self-assigned this Oct 31, 2018
@berquist berquist added the Implementation This provides an implementation for an algorithm. (Code and maybe md files are edited.) label Oct 31, 2018
System.out.format("has the solution:\n")

for (i in solution.indices) {
System.out.format("[% .5f]\n", solution[i])
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would try and keep this as pure Kotlin as possible. Unfortunately there isn't string interpolation with formatting like Python f-strings yet, but .format(varargs) can be used: https://stackoverflow.com/a/44340481

Suggested change
System.out.format("[% .5f]\n", solution[i])
println("[% .5f]".format(solution[i]))

@Gathros Gathros added the Hacktoberfest The label for all Hacktoberfest related things! label Oct 31, 2018
@berquist berquist merged commit 84aaa36 into algorithm-archivists:master Nov 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Hacktoberfest The label for all Hacktoberfest related things! Implementation This provides an implementation for an algorithm. (Code and maybe md files are edited.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants