Sha256: b4c095672dce14b9474278fbda5804eaec0e2061a936cf296c1830368d5d0766

Contents?: true

Size: 183 Bytes

Versions: 69

Compression:

Stored size: 183 Bytes

Contents

defmodule Gigasecond do
  def from(time) do
    seconds = :calendar.datetime_to_gregorian_seconds(time)
    :calendar.gregorian_seconds_to_datetime(seconds + 1_000_000_000)
  end
end

Version data entries

69 entries across 69 versions & 1 rubygems

Version Path
trackler-2.2.1.139 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.138 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.137 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.136 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.135 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.134 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.133 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.132 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.131 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.130 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.129 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.128 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.127 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.126 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.125 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.124 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.123 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.122 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.121 tracks/elixir/exercises/gigasecond/example.exs
trackler-2.2.1.120 tracks/elixir/exercises/gigasecond/example.exs