from typing import Iterable
from typing import Iterator


def iter_(iterable: Iterable) -> Iterator:
    """Returns appropriate iterator for the given iterable.
    This is mainly created because python's ``iter``
    returns an iterable of keys instead of keys and values for ``dict``.

    >>> tuple(iter_({1: "a", 2: "b", 3: "c"}))
    ((1, "a"),(2, "b"), (3, "c"))

    Added in version: 0.1.0
    """

    if isinstance(iterable, dict):
        # since iter(dict) returns a tuple of keys.
        # I want a tuple of key-value pairs
        return iter(iterable.items())

    return iter(iterable)