Skip to content

Instantly share code, notes, and snippets.

@r14152
Created August 15, 2021 08:46
Show Gist options
  • Save r14152/a433ee9e17540d9f3e64ef285195b49b to your computer and use it in GitHub Desktop.
Save r14152/a433ee9e17540d9f3e64ef285195b49b to your computer and use it in GitHub Desktop.
find the runner up hackerank solution
if __name__ == '__main__':
n = int(input())
arr = map(int, input().split())
print(sorted(set(arr))[-2])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment