Problem:
 Score : 100 points    Problem Statement  The door of Snuke's laboratory is locked with a security code.  The security code is a 4 -digit number. We say the security code is hard to enter when it contains two consecutive digits that are the same.  You are given the current security code S . If S is hard to enter, print Bad ; otherwise, print Good .      Constraints   S is a 4 -character string consisting of digits.         Input  Input is given from Standard Input in the following format:  S       Output  If S is hard to enter, print Bad ; otherwise, print Good .        Sample Input 1 3776      Sample Output 1 Bad  The second and third digits are the same, so 3776 is hard to enter.       Sample Input 2 8080      Sample Output 2 Good  There are no two consecutive digits that are the same, so 8080 is not hard to enter.       Sample Input 3 1333      Sample Output 3 Bad       Sample Input 4 0024      Sample Output 4 Bad

Solution (Python):
import sys
sys.setrecursionlimit(4100000)

a = input()
temp = "wwww"
counter = 0
for i in a:
    if i == temp:
        counter = 1
        break
    temp = i
if counter == 0:
    print("Good")
else:
    print("Bad")

Solution (Python):
S = input()
f = "Good"
for i in range(len(S)-1):
    if (S[i] == S[i+1]):
        f = "Bad"

print(f)

Solution (Python):



def main():
    
    S = list(input())
    flag = True
    for i in range(len(S)-1):
        if S[i] == S[i+1]:
            flag = False
    if flag:
        print('Good')
    else:
        print('Bad')
    
    


if __name__ == "__main__":
    main()

Solution (Python):
from sys import stdin
s = (stdin.readline().rstrip())
tmp = s[0]
flag = True
for i in s[1:]:
    if i == tmp:
        flag = False
    tmp = i
if flag:
    print("Good")
else:
    print("Bad")

Solution (Python):
S = input()

if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()
flg = 0
for i in range(3):
    if S[i] == S[i+1]:
        flg = 1
if flg == 1:
    print('Bad')
else:
    print('Good')

Solution (Python):
a=input()
cnt=0
for i in range(3):
    if a[i]==a[i+1]:
        cnt+=1
print("Good" if cnt==0 else "Bad")

Solution (Python):
s=list(map(int, list(input())))
flag=0
for i in range(3):
    if s[i]==s[i+1]:
        flag=1
if flag:
    print("Bad")
else:
    print("Good")

Solution (Python):


s = input()

if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
n=input()
ans="Good"
for i in range(3):
    if n[i]==n[i+1]:
        ans="Bad"
print(ans)

Solution (Python):
s = input().strip()
if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
s = input()

ans = "Good"

if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
  ans = "Bad"
print(ans)

Solution (Python):
a = input()
for i in range(3):
    if a[i] == a[i+1]:
        print("Bad")
        exit()
print("Good")

Solution (Python):
import sys


S = input()

ans = 'Bad'
for i in range(len(S) - 1):
    if S[i] == S[i + 1]: break
else:
    ans = 'Good'

print(ans)

Solution (Python):
S = input()
print("Bad" if S[0] == S[1] or S[1] == S[2] or S[2] == S[3] else "Good")

Solution (Python):
s = input()

prev_c = ""
ans = False
for c in s:
    if c == prev_c:
        ans = True
        break
    prev_c = c

if ans:
    print("Bad")
else:
    print("Good")

Solution (Python):

s = input()

if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
import sys,heapq
from collections import deque,defaultdict
printn = lambda x: sys.stdout.write(x)
inn = lambda : int(input())
inl   = lambda: list(map(int, input().split()))
inm   = lambda:      map(int, input().split())
DBG = True 
def ddprint(x):
  if DBG:
    print(x)

s = input()
if s[0]==s[1] or s[1]==s[2] or s[2]==s[3]:
    print("Bad")
else:
    print("Good")

Solution (Python):



def main():
    A = input()
    print('Bad' if A[0] == A[1] or A[1] == A[2] or A[2] == A[3] else 'Good')



if __name__ == '__main__':
    main()

Solution (Python):
S = input()
for i in range(1, len(S)):
    if S[i-1] == S[i]:
        print('Bad')
        exit()
print('Good')

Solution (Python):
S = list(input())

flag = False
for i in range(3):
    if S[i] == S[i+1]:
        flag = True
if flag:
    print ('Bad')
else:
    print ('Good')

Solution (Python):
s = input()

out = "Good"
before_c = s[0]
for c in s[1:]:
    if c == before_c:
        out = "Bad"
        break
    before_c = c

print(out)

Solution (Python):
S = input()

if (S[0]==S[1] or S[1]==S[2] or S[2]==S[3]):
  print ("Bad")
else:
  print ("Good")

Solution (Python):
import sys
s = str(input())
for i in range(3):
    if s[i] == s[i+1]:
        print('Bad')
        sys.exit()
print('Good')

Solution (Python):
s = input()

ans = 'Good'
for i in range(3):
    if s[i] == s[i+1]:
        ans = 'Bad'
        break

print(ans)

Solution (Python):
s = input()

if s[0]==s[1] or s[1]==s[2] or s[2]==s[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
def solve():
    S = input()
    for i in range(3):
        if S[i] == S[i + 1]:
            print("Bad")
            return True
    print("Good")
    return False


if __name__ == "__main__":
    solve()

Solution (Python):
S = input()

if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
s=input()

ans = 0
for i in range(3):
    if s[i] == s[i+1]:
        ans += 1

print('Bad') if ans >= 1 else print('Good')

Solution (Python):
s = input()
if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
  print("Bad")
else:
  print("Good")

Solution (Python):
def makelist(n, m):
    return [[0 for _ in range(m)] for _ in range(n)]






s = str(input())
ans = "Good"
for i in range(3):
    if s[i] == s[i+1]:
        ans = "Bad"
print(ans)

Solution (Python):
import sys
sys.setrecursionlimit(10**7)
INTMAX = 9223372036854775807
INTMIN = -9223372036854775808
DVSR = 1000000007
def POW(x, y): return pow(x, y, DVSR)
def INV(x, d=DVSR): return pow(x, d - 2, d)
def DIV(x, y, d=DVSR): return (x * INV(y, d)) % d
def LI(): return [int(x) for x in input().split()]
def LF(): return [float(x) for x in input().split()]
def LS(): return input().split()
def II(): return int(input())


S=input()
last=S[0]
res = 'Good'
for c in S[1:]:
    if c == last:
        res = 'Bad'
    last = c

print(res)

Solution (Python):

import sys


def solve(S: str):
    if(S[0] == S[1] or S[1] == S[2] or S[2] == S[3]):
        print('Bad')
    else:
        print('Good')
    return



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    S = str(next(tokens))  
    solve(S)

if __name__ == '__main__':
    main()

Solution (Python):
S = input()
flag = True
for i in range(len(S)-1):
    if S[i] == S[i+1]:
        flag = False
if flag:
    print("Good")
else:
    print("Bad")

Solution (Python):
S = input()
prev_digit = S[0]
for digit in S[1:]:
    if digit == prev_digit:
        print("Bad")
        exit(0)
    prev_digit = digit
print("Good")

Solution (Python):
s=input()

now=s[0]
for i in range(1,len(s)):
    if now==s[i]:
        print("Bad")
        quit()
    else:
        now=s[i]
print("Good")

Solution (Python):
S=input()
if S[0]==S[1] or S[1]==S[2] or S[2]==S[3]:
    print("Bad")
else:
    print("Good")

Solution (Python):
s = list(input())
count = 0
for i in range(len(s)-1):
    if s[i] == s[i+1]:
        count += 1

if count > 0:
    print("Bad")
else:
    print("Good")

Solution (Python):
def main():
    S = input()
    for i in range(3):
        if S[i] == S[i+1]:
            print("Bad")
            return
    print("Good")
    return


if __name__ == "__main__":
    main()

Solution (Python):
s = input()
p = ""
for c in s:
    if p == c:
        print("Bad")
        exit()
    p = c
print("Good")

Solution (Python):
s = input()
p = None

bad = False
for c in s:
    if p == c:
        bad = True
        break
    p = c

if bad:
    print('Bad')
else:
    print('Good')

Solution (Python):


S = list(input().strip())

p_n = 'x'
for n in S:
    if (n == p_n):
        print('Bad')
        exit()
    p_n = n


print('Good')

Solution (Python):
def main():
  v = list(map(int, input().strip()))

  for i in range(len(v) - 1):
    if v[i] == v[i + 1]:
      print('Bad')
      return

  print('Good')


if __name__ == '__main__':
  main()

Solution (Python):
import sys, itertools, collections
sys.setrecursionlimit(10**7)
def lmi(): return list(map(int, input().split()))

n = input()

for i in range(3):
    if n[i] == n[i+1]:
        print('Bad')
        break
else:
    print('Good')

Solution (Python):
S = input()

f = 0
for i, s in enumerate(S[:-1]):
    if s == S[i+1]:
        f = 1
if f == 1:
    print('Bad')
else:
    print('Good')

Solution (Python):

from __future__ import division, print_function

import os
import sys
from __builtin__ import xrange as range
from cStringIO import StringIO
from future_builtins import ascii, filter, hex, map, oct, zip
from io import IOBase

import __pypy__


def main():
    s = input()
    if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
        print('Bad')
    else:
        print('Good')




BUFSIZE = 8192


class FastI(IOBase):
    def __init__(self, file):
        self._fd = file.fileno()
        self._buffer = StringIO()
        self.newlines = 0

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count("\n") + (not b)
            ptr = self._buffer.tell()
            self._buffer.seek(0, 2), self._buffer.write(b), self._buffer.seek(ptr)
        self.newlines -= 1
        return self._buffer.readline()


class FastO(IOBase):
    def __init__(self, file):
        self._fd = file.fileno()
        self._buffer = __pypy__.builders.StringBuilder()
        self.write = lambda s: self._buffer.append(s)

    def flush(self):
        os.write(self._fd, self._buffer.build())
        self._buffer = __pypy__.builders.StringBuilder()


def print(*args, **kwargs):
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()


sys.stdin, sys.stdout = FastI(sys.stdin), FastO(sys.stdout)
input = lambda: sys.stdin.readline().rstrip("\r\n")



if __name__ == "__main__":
    main()

Solution (Python):

import sys
import math
import numpy as np
import itertools



s = list(input())

for i in range(3):
    if s[i]==s[i+1]:
        print('Bad')
        exit()

print('Good')

Solution (Python):
import sys
stdin = sys.stdin

sys.setrecursionlimit(10 ** 7)

def li(): return map(int, stdin.readline().split())
def li_(): return map(lambda x: int(x) - 1, stdin.readline().split())
def lf(): return map(float, stdin.readline().split())
def ls(): return stdin.readline().split()
def ns(): return stdin.readline().rstrip()
def lc(): return list(ns())
def ni(): return int(stdin.readline())
def nf(): return float(stdin.readline())

s = ns()
tf = True
for i,j in zip(s[:-1], s[1:]):
    if i == j:
        tf = False

print("Good" if tf else "Bad")

Solution (Python):
s = str(input())
s = list(s)
if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
    print("Bad")
else:
    print("Good")

Solution (Python):
S = list(input())
flag = False
for i in range(3):
    if S[i] == S[i+1]:
        flag = True
        break
if flag: print('Bad')
else: print('Good')

Solution (Python):
S = input()
flag = True
for i in range(3):
    if S[i] == S[i+1]:
        flag = False
print(["Bad","Good"][flag])

Solution (Python):
S = input()
ans = "Good"

for i in range(3):
  if S[i + 1] == S[i]:
    ans = "Bad"
print(ans)

Solution (Python):
s=input()
pre='
import sys
for i in s:
    if pre==i:
        print('Bad')
        sys.exit()
    else:
        pre=i
print('Good')

Solution (Python):

import sys
input = sys.stdin.readline

s = input()
flag = False

for i in range(1, len(s)):
    if (s[i] == s[i - 1]):
        flag = True

if (flag):
    print("Bad")
    exit()
print("Good")

Solution (Python):
p=""
ans="Good"
for s in input():
  if s==p:
    ans="Bad"
    break
  p=s
print(ans)

Solution (Python):
s=input()
for i in range(3):
  if s[i]==s[i+1]:
    print('Bad')
    break
else:
  print('Good')

Solution (Python):
import sys
S = input()

for i in range(1, len(S)):
    if S[i] == S[i - 1]:
        print('Bad')
        sys.exit(0)
print('Good')

Solution (Python):
s = input()
if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
    print("Bad")
else:
    print("Good")

Solution (Python):
a=input()
if a[0]==a[1] or a[1]==a[2] or a[2]==a[3]:
    print("Bad")
else:
    print("Good")

Solution (Python):




b = input()


ans = "Good"
for i in range(1, 4):
    if b[i] == b[i-1]:
        ans = "Bad"


print(ans)

Solution (Python):
S = input()
flg = 0
for i in range(1,len(S)):
  if S[i] == S[i-1]:
    flg = 1
if flg ==1:
  print('Bad')
else:
  print('Good')

Solution (Python):
s = input()
if s[0]==s[1] or s[1]==s[2] or s[2]==s[3]:
  print("Bad")
else:
  print("Good")

Solution (Python):



s = input()

if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
  print("Bad")
else:
  print("Good")

Solution (Python):
N=input()
print("Bad" if N[0]==N[1] or N[1]==N[2] or N[2]==N[3] else "Good")

Solution (Python):
s = input()
if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
  print("Bad")
else:
  print("Good")

Solution (Python):
S = input()

if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
	print("Bad")
else:
	print("Good")

Solution (Python):

def main():
    s = input()
    if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
        print("Bad")
    else:
        print("Good")


if __name__ == "__main__":
    main()

Solution (Python):
S = str(input())
for i in range(1,len(S)):
    if S[i] == S[i-1]:
        print("Bad")
        exit()
print("Good")

Solution (Python):
a = input()

if a[0] == a[1] or a[1] == a[2] or a[2] == a[3]:
    print("Bad")
else :
    print ("Good")

Solution (Python):
S = input()


if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()
if S[0]==S[1] or S[1]==S[2] or S[2]==S[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()
was = ''
for c in S:
    if c == was:
        print('Bad')
        quit()
    was = c
print('Good')

Solution (Python):
def main():
    S = input()
    if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
        print('Bad')
    else:
        print('Good')

main()

Solution (Python):
s=input()
if s[0]==s[1] or s[1]==s[2] or s[2]==s[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()

Flag = False
for i in range(1,len(S)):
    if S[i] == S[i-1]:
        Flag = True

if Flag == True:
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()
if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()

prev = None
for i in S:
    if i == prev:
        print("Bad")
        exit(0)

    prev = i

print("Good")

Solution (Python):
S = input()
dif = False
for i in range(len(S)-1):
    if S[i]==S[i+1]:
        dif=True
if dif:
    print("Bad")
else:
    print("Good")

Solution (Python):
s=input()
pre=' '
isBad=False
for si in s:
    if si==pre:
        isBad=True
    pre=si
if isBad:
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()

target = S[0]
for i in range(1, len(S)):
    if target == S[i]:
        print('Bad')
        exit()
    else:
        target = S[i]

print('Good')

Solution (Python):
s=input()
for i in range(3):
    if s[i]==s[i+1]:
        print('Bad')
        break
else:
    print('Good')

Solution (Python):
import sys
sys.setrecursionlimit(10**7)
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x) - 1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def II(): return int(sys.stdin.readline())
def SI(): return sys.stdin.readline().strip()
INF = 10 ** 18
MOD = 10 ** 9 + 7

from functools import lru_cache

def main(): 
    s = SI()
    if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
        print('Bad')
    else: print('Good')
      
main()

Solution (Python):
S = input()
flag = True
before = ""
for c in S:
    if before == c:
        flag = False
    before = c

if flag:
    print("Good")
else:
    print("Bad")

Solution (Python):
s = input()
ans = 'Good'
for i in range(len(s)-1):
    if s[i] == s[i+1]:
        ans = 'Bad'
print(ans)

Solution (Python):
code = input()

if code[0] == code[1] or code[1] == code[2] or code[2] == code[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):


import sys

def input(): return sys.stdin.readline().strip()
def list2d(a, b, c): return [[c] * b for i in range(a)]
def list3d(a, b, c, d): return [[[d] * c for j in range(b)] for i in range(a)]
def ceil(x, y=1): return int(-(-x // y))
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def Yes(): print('Yes')
def No(): print('No')
def YES(): print('YES')
def NO(): print('NO')
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
MOD = 10 ** 9 + 7

S=input()

for i in range(3):
    if S[i]==S[i+1]:
        print('Bad')
        exit()
print('Good')

Solution (Python):
import sys
from collections import Counter, deque, defaultdict
from itertools import accumulate, permutations, combinations, takewhile, compress, cycle
from functools import reduce
from math import ceil, floor, log10, log2, factorial
from pprint import pprint

sys.setrecursionlimit(1000000)






S = input()

if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
    print("Bad")
    sys.exit()

print("Good")
sys.exit()

Solution (Python):
import sys
import math 
ni = lambda: int(ns())
na = lambda: list(map(int, input().split()))
ns = lambda: input()

S = ns()
prev = S[0]
for s in S[1:]:
    if prev ==s:
        print("Bad")
        exit()
    prev =s
print("Good")

Solution (Python):
s = input()
if s[0]!=s[1] and s[1]!=s[2] and s[2]!=s[3]:
    print('Good')
else:
    print('Bad')

Solution (Python):
S = input()
for i in range(1,len(S)):
    if S[i] == S[i-1]:
        print("Bad")
        break
else:
    print("Good")

Solution (Python):
S = input()
if (S[0] == S[1]) or (S[1] == S[2]) or (S[2] == S[3]):
    print('Bad')
else:
    print('Good')

Solution (Python):
S = list(map(int, input()))
flg = 0

for i in range(3):
  if S[i] == S[i + 1]:
    flg = 1
    break
if flg == 0:
  print('Good')
else:
  print('Bad')

Solution (Python):
s =  str(input())

flag = True
for i in range(3):
    if s[i] == s[i+1]:
        flag = False

if flag:
    print("Good")
else:
    print("Bad")

Solution (Python):
from bisect import bisect_left, bisect_right; from collections import Counter, defaultdict, deque, OrderedDict; from copy import deepcopy; from fractions import gcd; from functools import lru_cache, reduce; from math import ceil, floor; from sys import stdin, setrecursionlimit
import heapq as hq; import itertools as its; import operator as op



inf = float('inf')
input = stdin.readline


def main():
    s = get_lc()
    if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
        print("Bad")
    else:
        print("Good")
    return


def get_int():
    return int(input())


def get_float():
    return float(input())


def get_str():
    return input().strip()


def get_li():
    return [int(i) for i in input().split()]


def get_lf():
    return [float(f) for f in input().split()]


def get_lc():
    return list(input().strip())


def get_data(n, types, sep=None):
    if len(types) == 1:
        return [types[0](input().strip()) for _ in range(n)]
    return list(zip(*(
        [t(x) for t, x in zip(types, input().strip().split(sep=sep))]
        for _ in range(n)
    )))


if __name__ == '__main__':
    setrecursionlimit(4100000)
    main()

Solution (Python):
N = list(input())
if N[0]==N[1] or N[1]==N[2] or N[2]==N[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):



import sys
sys.dont_write_bytecode = True
stdin = sys.stdin
input = stdin.readline
sys.setrecursionlimit(10000000)






import math, itertools, operator
from math import *
from math import factorial as fact
from operator import itemgetter, attrgetter
from itertools import permutations, combinations
from functools import reduce, lru_cache


from fractions import gcd
from fractions import Fraction as Frac

inf = float('inf')

def lcm(a, b):
    return a * b // gcd(a,b)

def perm(a, b):
    import scipy.special
    return scipy.special.perm(a, b, exact = True)

def comb(a, b):
    import scipy.special
    return scipy.special.comb(a, b, exact = True)

def dfact(n):
    import scipy.special
    return scipy.special.factorial2(n, exact = True)

def prod(l):
    return reduce(operator.mul, l)

def input_ints(func = input, sep = None, conv = int):
    return list(map(conv, func().split(sep = sep)))




def main():
    
    S = input()
    for i in range(3):
        if S[i] == S[i+1]:
            print('Bad')
            return
    print('Good')


if __name__ == '__main__':
    main()

Solution (Python):
s=input()
if(s[0]==s[1] or s[1]==s[2] or s[2]==s[3]):
    print("Bad")
else:
    print("Good")

Solution (Python):
S = input()

check = 0
pre = S[0]
for i in range(3):
    if S[i+1] == pre:
        check = 1
    else:
        pre = S[i+1]

if check == 0:
    print('Good')
else:
    print('Bad')

Solution (Python):
S = input()

t = ""
for a in S:
    if t == a:
        print('Bad')
        break
    t = a
else:
    print('Good')

Solution (Python):
s = input()
for i in range(len(s)-1):
    if s[i] == s[i+1]:
        print('Bad')
        exit()
print('Good')

Solution (Python):
import sys
N = input()

form=""
for s in N:
    if form == s:
        print("Bad")
        sys.exit()
    else:
        pass
    form = s
print("Good")

Solution (Python):
s = input()

ans = "Good"

if s[0] == s[1]:
  ans = "Bad"
if s[1] == s[2]:
  ans = "Bad"
if s[2] == s[3]:
  ans = "Bad"
print(ans)

Solution (Python):
s=input()
a=s[0]
b=s[1]
c=s[2]
d=s[3]

if a==b or b==c or c==d:
	print("Bad")
else:
	print("Good")

Solution (Python):
import sys
sys.setrecursionlimit(1000000)
 
s = input()

for i in range(len(s)-1):
    if s[i] == s[i+1]:
        print("Bad")
        exit()
        
print("Good")

Solution (Python):
S = input()

def f():
    p = ""
    for s in S:
        if p == s:
            return True
        p = s

    return False

print("Bad" if f() else "Good")

Solution (Python):
S = input()
for i in range(len(S) - 1):
    if S[i] == S[i + 1]:
        print('Bad')
        break
else:
    print('Good')

Solution (Python):
s = input()
if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
    print('Bad')
else:print("Good")

Solution (Python):
s=input()
r="Good"
for i in range(3):
  if s[i]==s[i+1]:
    r="Bad"
print(r)

Solution (Python):


def read_input():
    s = input()
    cs = [c for c in s]

    return cs


def submit():
    cs = read_input()

    for c1,c2 in zip(cs, cs[1:]):
        if c1 == c2:
            print('Bad')
            return

    print('Good')
    return


if __name__ == '__main__':
    submit()

Solution (Python):
import sys

def main():
    input = sys.stdin.readline
    S = str(input().strip())

    a = ''
    for s in S:
        if s == a:
            return 'Bad'
        a = s

    return 'Good'


if __name__ == '__main__':
    print(main())

Solution (Python):
import sys

readline = sys.stdin.readline

S = readline().rstrip()

if any(S[i] == S[i + 1] for i in range(len(S) - 1)):
    print('Bad')
else:
    print('Good')

Solution (Python):
S = input()

ans = 'Good'
for i in range(1, len(S)):
    if S[i] == S[i-1]:
        ans = 'Bad'
        break

print(ans)

Solution (Python):
S = input()
for i in range(len(S)-1):
    if S[i] == S[i+1]:
        print("Bad")
        exit()
print("Good")

Solution (Python):
S = input()

is_good = True
for i in range(3):
    if S[i] == S[i+1]:
        is_good = False
    
print("Good") if is_good else print("Bad")

Solution (Python):
s = input()
print("Bad" if s[0]==s[1] or s[1]==s[2] or s[2]==s[3] else "Good")

Solution (Python):

S = input()

flag = False
for i in range(3):

    if S[i] == S[i+1]:
        flag = True

if flag:
    print ("Bad")
else:
    print ("Good")

Solution (Python):
S = list(input())
c = 0
for i in range(3):
    if S[i] == S[i+1]:
        c += 1
if c >= 1:
    print("Bad")
else:
    print("Good")

Solution (Python):






s=input()


if s[0] == s[1] or s[1] == s[2] or s[2] == s[3]:
    print("Bad")
else:
    print("Good")

Solution (Python):
import sys

def main():
    a = sys.stdin.readline().strip()
    
    
    f = 'Good'
    for i in range(3):
        if a[i] == a[i+1]:
            f = 'Bad'

    print(f)

main()

Solution (Python):
s = list(input())

cnt = 0

for i in range(3):
    if s[i] == s[i+1]:
        cnt = 1
        
print("Good" if cnt == 0 else "Bad")

Solution (Python):
s = input()
if (s[0]==s[1])|(s[1]==s[2])|(s[2]==s[3]):
  print("Bad")
else:
  print("Good")

Solution (Python):
S = input()
pre = -1
for i in range(4):
    if S[i] == pre:
        print('Bad')
        exit()
    pre = S[i]

print('Good')

Solution (Python):
S = input().rstrip()
tmp = ''
result = 'Good'

for s in S:
    if tmp == s:
        result = 'Bad'
    tmp = s

print(result)

Solution (Python):
S=input()
for i in range(10):
    if S.count(str(i)+str(i)):
        print('Bad')
        break
else:
    print('Good')

Solution (Python):
s = list(input())
for i in range(3):
	if s[i] == s[i+1]:
		print("Bad")
		exit()
print("Good")

Solution (Python):
s = input()

flag = False
for i in range(3):
    if s[i] == s[i+1]:
        flag = True

if flag:
    print('Bad')
else:
    print('Good')

Solution (Python):
s = input().strip()
ans = "Good"
p = s[0]
for i in range(1, len(s)):
    if p == s[i]:
        ans = "Bad"
        break
    p = s[i]
print(ans)

Solution (Python):
S=input()

for a in range(3):
    if S[a]==S[a+1]:
        print("Bad")
        break
else:
    print("Good")

Solution (Python):
s = input()
last = s[0]
flag = 0
for c in s[1:]:
    if c == last:
        flag = 1
    last = c
if flag:
    print("Bad")
else:
    print("Good")

Solution (Python):
s=input()
for i in range(len(s)-1):
    if s[i] == s[i+1]:
        print('Bad')
        exit(0)
print('Good')

Solution (Python):
def debug(*args):
    import sys
    print(*args, file=sys.stderr)

def solve():
    pass

def main():
    S = input()
    for i in range(1, len(S)):
        if S[i-1] == S[i]:
            return "Bad"
    return "Good"

print(main())

Solution (Python):

from __future__ import division, print_function

import os
import sys
from io import BytesIO, IOBase

if sys.version_info[0] < 3:
    from __builtin__ import xrange as range
    from future_builtins import ascii, filter, hex, map, oct, zip


def main():
    s = input()

    p = s[0]
    for i in s[1:]:
        if i == p:
            print('Bad')
            return
        p = i

    print('Good')




BUFSIZE = 8192


class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)


class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")


def print(*args, **kwargs):
    """Prints the values to a stream, or to sys.stdout by default."""
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()


if sys.version_info[0] < 3:
    sys.stdin, sys.stdout = FastIO(sys.stdin), FastIO(sys.stdout)
else:
    sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)

input = lambda: sys.stdin.readline().rstrip("\r\n")



if __name__ == "__main__":
    main()

Solution (Python):
import numpy as np
import math
import sys
sys.setrecursionlimit(10000000)

def main():
    S = input()
    for i in range(3):
        if S[i] == S[i + 1]:
            print("Bad")
            break
    else:
        print("Good")

if __name__ == '__main__':
    main()

Solution (Python):


s=input()
tp="A"
for i in range(4):
    if s[i]==tp:
        print("Bad")
        exit()
    
    tp=s[i]
print("Good")

Solution (Python):
s=list(input())
ans='Good'
for i in range(3):
    if s[i]==s[i+1]:
        ans='Bad'
print(ans)

Solution (Python):

S = str(input())
if S[0] == S[1] or S[1]==S[2] or S[2]==S[3]:
    print("Bad")
else:
    print("Good")

Solution (Python):
s = input()
if s[0]==s[1] or s[1]==s[2] or s[2]==s[3]:
    print('Bad')
else:
    print('Good')

Solution (Python):

from collections import defaultdict
import math
import re

def main():
    
    S = input().strip()

    for i in range(len(S)-1):
        if S[i] == S[i+1]:
            print("Bad")
            return
    print("Good")

if __name__ == '__main__':
    main()

Solution (Python):
import sys,collections as cl,bisect as bs
sys.setrecursionlimit(100000)
Max = sys.maxsize
def l(): 
    return list(map(int,input().split()))
def m(): 
    return map(int,input().split())
def onem(): 
    return int(input())
def s(x): 
    a = []
    aa = x[0]
    su = 1
    for i in range(len(x)-1):
        if aa == x[i+1]:
            a.append([aa,su])
            aa = x[i+1]
            su = 1
        else:
            su += 1
    a.append([aa,su])
    return a
def jo(x): 
    return " ".join(map(str,x))
def max2(x): 
    return max(map(max,x))

n = list(input())
a = n[0]

for i in range(1,4):
    if a == n[i]:
        print("Bad")
        exit()
    a = n[i]
print("Good")

Solution (Python):
S=input()

for i in range(3):
    if S[i]==S[i+1]:
      print('Bad')
      exit()
print('Good')

Solution (Python):
import sys
s = input()
for i in range(3):
    if s[i] == s[i+1]:
        print("Bad")
        sys.exit()
print("Good")