const main = (input) => {
    S = input.split("").map(n => Number(n));
    if (S[0] !== S[1] && S[1] !== S[2] && S[2] !== S[3]) {
        console.log("Good");
    } else {
        console.log("Bad");
    }
};

main(require("fs").readFileSync("/dev/stdin", "utf8"));