package main import ( "bufio" "fmt" "log" "os" "strconv" ) func main() { log.SetFlags(log.Lshortfile) perfect := nextInt() great := nextInt() good := nextInt() miss := nextInt() if miss >= 10 { fmt.Println("Impossible") } else { var score int point := 50 cmb := 1 var i = 1 for ; i <= great; i++ { score += point * cmb if i%100 == 0 { cmb *= 2 } } point = 100 for ; i <= perfect+great; i++ { score += point * cmb if i%100 == 0 { cmb *= 2 } } fmt.Println("Possible") fmt.Println(score) } log.Println(good) } func max(a ...int) int { r := a[0] for i := 0; i < len(a); i++ { if r < a[i] { r = a[i] } } return r } func min(a ...int) int { r := a[0] for i := 0; i < len(a); i++ { if r > a[i] { r = a[i] } } return r } func sum(a []int) (r int) { for i := range a { r += a[i] } return r } func minmax(a, b int) (int, int) { if a > b { return b, a } return a, b } func abs(a int) int { if a < 0 { return -a } return a } type Pair struct { a, b int } type Pairs []Pair func (p Pairs) Len() int { return len(p) } func (p Pairs) Swap(i, j int) { p[i], p[j] = p[j], p[i] } func (p Pairs) Less(i, j int) bool { return p[i].b < p[j].b } var nextReader func() string func init() { nextReader = NewScanner() } func NewScanner() func() string { r := bufio.NewScanner(os.Stdin) r.Buffer(make([]byte, 1024), int(1e+11)) r.Split(bufio.ScanWords) return func() string { r.Scan() return r.Text() } } func nextString() string { return nextReader() } func nextInt64() int64 { v, _ := strconv.ParseInt(nextReader(), 10, 64) return v } func nextInt() int { v, _ := strconv.Atoi(nextReader()) return v } func nextInts(n int) []int { r := make([]int, n) for i := 0; i < n; i++ { r[i] = nextInt() } return r } func nextFloat64() float64 { f, _ := strconv.ParseFloat(nextReader(), 64) return f }