Problem Description

Read n and then k indices (0-based). Build a bitmask with those bits set and output it as integer.

Input Format

First line n k. Second line: k indices.

Output Format

One integer mask.

Sample Test Case

Input:
10 3 0 3 5
Output:
41

Constraints

0

Solutions (0)

No solutions submitted yet. Be the first!

Discussion (0)

No comments yet. Start the discussion!

Prev Next