Nộp bài | Các bài nộp | Làm tốt nhất | Về danh sách bài |

## VSORTDESCABSSLOW - Basic Sorting with Custom Order |

Given a sequence of n integers a_{1}, a_{2},... a_{n}. Sort it in descending order of absolute value (|a'^{1}| ≥ |a'^{2}| ≥ ... ≥ |a'^{n}|). Note that if two items have the same absolute value, the positive one comes first in the list.

### Input

Line 1: contains the integer n (1 ≤ n ≤ 10^{3}).

Line 2 to n + 1: (i + 1)-th line contains the integer a_{i} (|a_{i}| ≤ 10^{9})

### Output

Line 1 to n: each line contains each item of the sequence in desired order.

### Example

Input:3

1

3

2Output:3

2

1

Được gửi lên bởi: | Viet-Hoa Do |

Ngày: | 2017-07-17 |

Thời gian chạy: | 1s |

Giới hạn mã nguồn: | 50000B |

Memory limit: | 1536MB |

Cluster: | Cube (Intel G860) |

Ngôn ngữ cho phép: | ASM32-GCC ASM32 ASM64 BASH C-CLANG C C++ 4.3.2 CPP CPP14 CPP14-CLANG C99 GO |