Module Expr Str Assign NameStore Str ClassDef bases NameLoad body FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call NameLoad NameLoad Assign NameStore Num While CompareLt NameLoad NameLoad body Assign NameStore SubscriptLoad NameLoad Index NameLoad If BoolOpOr CompareLtE NameLoad Num CompareGt NameLoad NameLoad body AugAssignAdd NameStore Num orelse If CompareNotEq SubscriptLoad NameLoad Index BinOpSub NameLoad Num NameLoad body Assign TupleStore SubscriptStore NameLoad Index BinOpSub NameLoad Num SubscriptStore NameLoad Index NameLoad TupleLoad NameLoad SubscriptLoad NameLoad Index BinOpSub NameLoad Num orelse AugAssignAdd NameStore Num For NameStore Call NameLoad NameLoad body If CompareNotEq SubscriptLoad NameLoad Index NameLoad BinOpAdd NameLoad Num body Return BinOpAdd NameLoad Num Return BinOpAdd NameLoad Num decorator_list decorator_list If CompareEq NameLoad Str body Assert CompareEq Call AttributeLoad Call NameLoad attr ListLoad Num Num Num Num Num
N/A N/A 
Given an unsorted integer array, find the first missing positive integer.

Example
Given [1,2,0] return 3, and [3,4,-1,1] return 2.

Challenge
Your algorithm should run in O(n) time and uses constant space.
 N/A __author__ Daniel Solution N/A object N/A firstMissingPositive N/A N/A self A N/A N/A N/A n N/A len A N/A i 0 N/A N/A i n N/A N/A v N/A A N/A i N/A N/A N/A v 0 N/A v n N/A N/A i 1 N/A N/A N/A N/A A N/A N/A v 1 v N/A N/A N/A N/A A N/A N/A v 1 N/A A N/A i N/A v N/A A N/A N/A v 1 N/A N/A i 1 N/A i N/A xrange n N/A N/A N/A N/A A N/A i N/A i 1 N/A N/A N/A i 1 N/A N/A n 1 N/A N/A N/A N/A __name__ __main__ N/A N/A N/A N/A N/A N/A Solution firstMissingPositive N/A 3 4 -1 1 2