my-solutions/leetcode/0002-add-two-numbers/types.rb

9 lines
162 B
Ruby
Raw Normal View History

2022-11-28 22:15:37 +05:00
# Definition for singly-linked list.
class ListNode
attr_accessor :val, :next
def initialize(val = 0, _next = nil)
@val = val
@next = _next
end
end