【文件属性】:
文件名称:leetcode-ruby
文件大小:6KB
文件格式:ZIP
更新时间:2021-06-17 19:36:44
Ruby
leetcode-ruby
Minitest 用于单元测试
gem install minitest
需要安装 Ruby-Graphviz 库才能使用 drawTree() 函数
来源: :
gem install graphviz
gem install ruby-graphviz
对于二叉树,如下所示
1
/ \
2 3
\
4
该函数将在相同目录中生成一个 png 文件,如下所示:
【文件预览】:
leetcode-ruby-master
----roman_to_integer.rb(772B)
----excel_sheet_column_title.rb(347B)
----integer_to_roman.rb(453B)
----binary_tree_inorder_traversal.rb(585B)
----best_time_to_buy_sell_stock.rb(269B)
----binarytree.rb(845B)
----best_time_to_buy_sell_stockII.rb(464B)
----binary_tree_preorder_traversal.rb(690B)
----remove_nth_node_from_end_of_list.rb(622B)
----rotate_array.rb(257B)
----.gitignore(573B)
----list.rb(309B)
----README.md(473B)
----excel_sheet_column_number.rb(290B)