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



Sample input:
3776


Sample output:
Bad

Submission status: Accepted

Solution code:
S = input()
for i in range(3):
  if S[i]==S[i+1]:
    print('Bad')
    break
  else:
    pass
else:
  print("Good")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
 
tmp = ""
for val in s:
  if tmp == val:
    print("Bad")
    import sys
    sys.exit(0)
  tmp = val
 
print("Good")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

bad = 0
for i in range(1,4):
    if s[i] == s[i-1]:
        print('Bad')
        bad = 1
        break
if bad==0:
    print('Good')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
S = list(input(""))
count = 0

for i in range(1,4):
    if S[i] == S[i - 1]:
        count += 1
        continue


if count >= 1:
    print("Bad")
elif count == 0:
    print("Good")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()

d=False
for i in range(len(S)-1):
    s=S[i:i+2]
    if s[0] != s[1]:
        d=True
    else:
        print('Bad')
        exit()

if d:
    print('Good')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = list(input())
pre = s[0]

for i in range(1, 4):
    if pre == s[i]:
        print("Bad")
        break
    else:
        pre = s[i]
        if i == 3:
            print("Good")
            break

Submission status: Accepted

Solution code:
s = input()
ans = 0
for i in range(len(s)-1):
    if s[i] == s[i+1]:
        ans += 1

if ans >= 1:
    print("Bad")
else :
    print("Good")

Submission status: Accepted

Solution code:
import copy
import sys
from _operator import itemgetter
from collections import Counter
from math import log2, pi, ceil

stdin = sys.stdin

ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
ns = lambda: stdin.readline().rstrip()

flag = True
s = input()
for i in range(3):
    if s[i] == s[i+1]:
        flag = False
        break
print("Good" if flag else "Bad")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = list(input())

before = None
for e in s:
    if before == e:
        print("Bad")
        exit()
    else:
        before = e
print("Good")

Submission status: Accepted

Solution code:
s=list(input())
j=0
for i in range(3):
	if s[i]!=s[i+1]:
		j+=1
	else:
		print('Bad')
		break
if j==3:
	print('Good')

Submission status: Accepted

Solution code:
#131 a
s=list(input())
if s[0]!=s[1] and s[1]!=s[2] and s[2]!=s[3]:
    print("Good")
else:
    print("Bad")

Submission status: Accepted

Solution code:
s=list(str(input()))
l=len(s)
s1=s[0]
for i in range(1,l):
    if(s1==s[i]):
        print('Bad')
        exit()
    else:
        s1 = s[i]
        continue
print('Good')

Submission status: Accepted

Solution code:
# -*- coding:utf8 -*-

s = input()
ans = 'Good'
for i, n in enumerate(s[:3]):
    if s[i + 1] == n:
        ans = 'Bad'
print(ans)

Submission status: Accepted

Solution code:
S = list(map(int,input()))
for i in range(3):
  if S[i]==S[i+1]:
    print("Bad")
    exit()
print("Good")

Submission status: Accepted

Solution code:
S = list(map(int,input()))
cnt=0
for i in range(3):
  if S[i]==S[i+1]:
    cnt +=1
if cnt>0:
  print("Bad")
else:
  print("Good")

Submission status: Accepted

Solution code:
s=input()
ans="Good"
for i in range(1,4):
  if s[i]==s[i-1]:
    ans="Bad"
print(ans)

Submission status: Accepted

Solution code:
s= input()
for i in range(1, 4):
  if s[i-1]==s[i]:
    print('Bad')
    exit()
print('Good')

Submission status: Accepted

Solution code:
str = input()
p = 0
result = "Good"
for s in str:
    if p == s :
        result = "Bad"
    p = s
print(result)

Submission status: Accepted

Solution code:
s = list(input())
flg = False

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

if not flg:
    print('Good')
else:
    print('Bad')

Submission status: Accepted

Solution code:
S=input()
dist=0
for i in range(len(S)-1):
    if int(S[i])==int(S[i+1]):
        dist=dist+1
    else:pass
if dist==0:
    output="Good"
else:output="Bad"
print(output)

Submission status: Accepted

Solution code:
s = input()
def judge(s):
  for i in range(len(s)-1):
    if s[i] == s[i+1]:
      return print("Bad")
  return print("Good")

def judge2(s):
    if s[0] != s[1] and s[1] != s[2] and s[2] != s[3]:
        return print("Good")
    else:
        return print("Bad")

judge2(s)

Submission status: Accepted

Solution code:
List=list(input())
a=List[0]
b=List[1]
c=List[2]
d=List[3]
if a!=b and b!=c and c!=d:
    print("Good")
else:print("Bad")

Submission status: Accepted

Solution code:
def main(): 

    S = input()

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

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
s = input()
result = "Good"

pre = s[0]
for i in range(1, len(s)):
    if pre == s[i]:
        result = "Bad"
    else:
        pre = s[i]

print(result)

Submission status: Accepted

Solution code:
x = [int(i) for i in input()]
count = 0

for i in range(len(x)-1):
  if x[i] == x[i+1]:
    count += 1

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

Submission status: Accepted

Solution code:
s=str(input())

def is_s_safe(n):
    for i in range (0,3):
        if s[i]==s[i+1]:
            return "Bad"
    return "Good"
print (is_s_safe(s))

Submission status: Accepted

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

Submission status: Accepted

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

print("Good")

Submission status: Accepted

Solution code:
S = str(input())
S = list(S)
if S[0] == S[1] or S[2] == S[3] or S[1] == S[2]:
    ans = ("Bad")
else:
    ans = ("Good")

print(str(ans))

Submission status: Accepted

Solution code:
s = list(input())
judge = False
if s[0] == s[1]:
    judge = True
if s[1] == s[2]:
    judge = True
if s[2] == s[3]:
    judge = True
if judge:
    print('Bad')
else:
    print('Good')

Submission status: Accepted

Solution code:
a = input()

x = 0

for i in range(3):
    if a[i] == a[i+1]:
        x += 1

print("Good" if x == 0 else "Bad")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = str(input())
a = 'a'

for x in S:
    if a == x:
        print ( 'Bad' )
        exit(0)
    a = x
 
print ( 'Good' )

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
s_list = [i for i in s]
if s_list[0] != s_list[1] and s_list[1] != s_list[2] and s_list[2] != s_list[3]:
  print('Good')
  exit()
print('Bad')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()

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

else:
  print ('Good')

Submission status: Accepted

Solution code:
S=list(input())

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

Submission status: Accepted

Solution code:
S = str(input())
k = 1
for i in range(3):
    if S[i] == S[i+1]:
        print("Bad")
        k = 0
        break
    else:
        continue
if k == 1:
    print("Good")

Submission status: Accepted

Solution code:
s = input()

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

print("Good" if solve(s) else "Bad")

Submission status: Accepted

Solution code:
s = str(input())

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

Submission status: Accepted

Solution code:
s = list(input())
c = 0
for i in range(3):
    if s[i] == s[i+1]:
        c += 1
if c == 0:
    print('Good')
else:
    print('Bad')

Submission status: Accepted

Solution code:
a = input()
b = 0

for x in range(int(len(str(a))) - 1):
    if a[x] == a[x + 1]:
        b += 1

if b > 0:
    print('Bad')
else:
    print('Good')

Submission status: Accepted

Solution code:
s = input()
p = ""
result = "Good"
for i in s:
    if p == i:
        result = "Bad"
    p = i
print(result)

Submission status: Accepted

Solution code:
s = list(input())
cnt = 0
for i in range(3):
    if s[i] == s[i+1]:
        cnt += 1
if cnt == 0:
    print('Good')
else:
    print('Bad')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = input()

num = -1
good_flg = True
for i in n:
    if num == i:
        print('Bad')
        good_flg = False
        break
    num = i
if good_flg:
    print('Good')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
while True:
    try:
        S = input()
        
        for i in range(len(S)-1):
            if S[i] == S[i+1]:
                print("Bad")
                break
        else:
            print("Good")
    except:
        break

Submission status: Accepted

Solution code:
f = True
a = input()
s = [str(c) for c in a]
for i in range(3):
    if(s[i] == s[i + 1]):
        f = False
if f:
    print('Good')
else:
    print('Bad')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

def main():
    s = input()

    for i in range(1, 4):
        if s[i] == s[i - 1]:
            print("Bad")
            sys.exit()
    else:
        print("Good")

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
s=list(input())
flag=0
for i in range(3):
  if s[i]==s[i+1]:
    flag=1
if flag:
  print('Bad')
else:
  print('Good')

Submission status: Accepted

Solution code:
from sys import stdin

s = stdin.readline().rstrip()
prev = s[0]
f = True

for x in s[1:]:
  if prev == x:
    f = False
    break
  else:
    prev = x
    
if f:
  print("Good")
else:
  print("Bad")

Submission status: Accepted

Solution code:
S=input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b,c,d = input()
if a != b and b != c and c != d:
  print('Good')
else:
  print('Bad')

Submission status: Accepted

Solution code:
s_list = list(str(input()))
count = 0
for i in range(3):
    if s_list[i] == s_list[i+1]:
        count = 1
if count == 0:
    print("Good")
else:
    print("Bad")

Submission status: Accepted

Solution code:
input = input()
s=list(input)
prev = s[0]

ret = 'Good'
for i in range(1,4):
    if s[i] == prev:
        ret = 'Bad'
    prev = s[i]
print(ret)

Submission status: Accepted

Solution code:
s = str(input())

last = None
for i in list(s):
  if last == i:
    print("Bad")
    exit()
  last = i
print("Good")

Submission status: Accepted

Solution code:
def main():
    s = list(str(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()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = input()
a,b,c,d = list(n)

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
m= input()

if m[0] != m[1] and m[1] != m[2] and m[2] != m[3]:
    print('Good')
else:
    print('Bad')

Submission status: Accepted

Solution code:
s = input()

word = ''
for i in range(len(s)):
    if word == s[i]:
        print('Bad')
        exit()
    word = s[i]
print('Good')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
isGood = 'Good'
prev = ''

for c in s:
	if prev != '' and prev == c:
		isGood = 'Bad'
	prev = c

print(isGood)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = input()
t = a[0]
flag = 0
for i in a[1:]:
    if t == i:
        flag = 1
    t = i
if flag:
    print("Bad")
else:
    print("Good")

Submission status: Accepted

Solution code:
import sys
from math import ceil

def input():
    return sys.stdin.readline().strip()

def iinput():
    return int(input())

def finput():
    return float(input())

def tinput():
    return input().split()

def rinput():
    return map(int, tinput())

def rlinput():
    return list(rinput())

def nok(a, b):
    m = a * b
    while a != 0 and b != 0:
        if a > b:
            a %= b
        else:
            b %= a
    return m // (a + b)    


def main():
    a = list(input())
    if a[0] == a[1] or a[1] == a[2] or a[3] == a[2]:
        print("Bad")
        return 0
    print("Good")
    
    
    
    
main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
l = 'p'
t = 0
for i in input():
    if l == i:
        t+=1
    l = i
if t:
    print('Bad')
else:
    print('Good')

Submission status: Accepted

Solution code:
S = input()

flag = 0
for i in range(len(S)-1) : 
    if S[i] == S[i+1] : 
        flag = 1

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input().split()
flag = True
for i in range(len(s[0]) - 1):
    if s[0][i] == s[0][i + 1]:
        flag = False
        print('Bad')
        break
if flag:
    print('Good')

Submission status: Accepted

Solution code:
s = input()
tmp = s[0]
i = 1
ans = "Good"
while(i < 4):
    if tmp == s[i]:
        ans = "Bad"
        break
    tmp = s[i]
    i += 1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = list(input())
for a, b in zip(S[:-1],S[1:]):
    if a == b:
        print("Bad")
        break
else:
    print("Good")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = list(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = list(input())
for a, b in zip(S[:-1],S[1:]):
    if a == b:
        print("Bad")
        exit()
print("Good")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

S = input()

n = ""
for s in S:
    if s == n:
        print("Bad")
        sys.exit()
    n = s

print("Good")

Submission status: Accepted

Solution code:
s = input()
pre = s[0]
for x in s[1:]:
    if x == pre:
        print("Bad")
        exit()

    pre = x

print("Good")

Submission status: Accepted

Solution code:
s = input()
for c1, c2 in zip(s, s[1:]):
    if c1 == c2:
        print("Bad")
        break
else:
    print("Good")

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
li = list(input())
flag = False
for i in range(len(li)):
  if i == 0:
    continue
  flag = li[i-1] == li[i]
  if flag:
    break
print("Bad" if flag else "Good")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
is_bad = False
for a, b in zip(s, s[1:]):
    if a == b:
        is_bad = True
        break
if is_bad:
    print("Bad")
else:
    print("Good")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=input()
for i in range(1,4):
  if s[i]==s[i-1]:
    print("Bad")
    exit()


print("Good")

Submission status: Accepted

Solution code:
s = input()
for i in range(0,3):
  if s[i] == s[i+1]:
    print('Bad')
    exit()
print('Good')

Submission status: Accepted

Solution code:
s=input()
a=0
for i in range(3):
  if s[i]==s[i+1]:
    a+=1
print('Bad' if a>0 else 'Good')

Submission status: Accepted

Solution code:
S = list(input())
for i in range(1,4):
    if S[i-1] == S[i]:
        print("Bad")
        exit()
print("Good")

Submission status: Accepted

Solution code:
s = input()
s_list = [i for i in s]
flag = True
for i in range(1,4):
  if s_list[i]==s_list[i-1]:
    print('Bad')
    flag = False
    break

if flag:
  print('Good')

Submission status: Accepted

Solution code:
S = input()
tmp = S[0]
for num in S[1:]:
    if num == tmp:
        print('Bad')
        exit()
    tmp = num
print('Good')

Submission status: Accepted

Solution code:
b=''
for x in input():
    a=x
    if a==b:
        print('Bad')
        break
    else:
        b=a
else:
    print('Good')

Submission status: Accepted

Solution code:
import sys
S = input()
for i in range(len(S)-1):
  if S[i] == S[i+1]:
    print('Bad')
    sys.exit()
print('Good')

Submission status: Accepted

Solution code:
s = list(map(int, input()))
flg = 1
for i in range(4) :
  if i != 0 :
    if s[i -1] == s[i] :
      flg = 0
if flg == 1 :
  print("Good")
else :
  print("Bad")

Submission status: Accepted

Solution code:
S=str(input())
s_pre=""
flag=False
for i,s in enumerate(S):
  if i==0:
    pass
  else:
    if s_pre==s:
      flag=True
      break
  s_pre=s
if flag:
  print("Bad")
else:
  print("Good")

Submission status: Accepted

Solution code:
S = input()

ans = True
x = ''
for si in S:
    if x == si:
        ans = False
    x = si

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

Submission status: Accepted

Solution code:
lst = list(str(input()))
flag = 0
for i in range(3):
    if lst[i] == lst[i+1]:
        flag += 1
if flag == 0:
    print('Good')
else:
    print('Bad')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = str(input())
tmp = S[0]

for i in range(1, 4):
    if tmp == S[i]:
        print("Bad")
        break

    elif i == 3:
        print("Good")

    else:
        tmp = S[i]

Submission status: Accepted

Solution code:
S = list(str(input()))

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

Submission status: Accepted

Solution code:
S = list(input())
if S[0]!=S[1] and S[1]!=S[2] and S[2]!=S[3]:
    print("Good")
else:
    print("Bad")

Submission status: Accepted

Solution code:
# 文字列の入力
S = input()

# 同じ数字が連続する場合
if S[0] == S[1] or S[1] == S[2] or S[2] == S[3]:
  print("Bad")

# 同じ数字が連続しない場合
else:
  print("Good")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = list(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursionlimit(10000)
INF = float("inf")
YES, Yes, yes, NO, No, no = "YES", "Yes", "yes", "NO", "No", "no"
dy4, dx4 = [0, 1, 0, -1], [1, 0, -1, 0]
dy8, dx8 = [0, -1, 0, 1, 1, -1, -1, 1], [1, 0, -1, 0, 1, 1, -1, -1]


def inside(y, x, H, W):
    return 0 <= y < H and 0 <= x < W


def ceil(a, b):
    return (a + b - 1) // b


# 初項s, 交差dのn個の数列の和
def sum_of_arithmetic_progression(s, d, n):
    return n * (2 * s + (n - 1) * d) // 2


# aとbの最大公約数
def gcd(a, b):
    if b == 0:
        return a
    return gcd(b, a % b)


# aとbの最小公倍数
def lcm(a, b):
    g = gcd(a, b)
    return a / g * b


def main():
    S = input()
    if S[0] != S[1] and S[1] != S[2] and S[2] != S[3]:
        print("Good")
    else:
        print("Bad")


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
S = input()
count = 0
for i in range(len(S) - 1):
    if S[i] == S[i + 1]:
        count += 1
print("{}".format("Bad" if count > 0 else "Good"))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from sys import exit

S = input()

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

print('Good')

Submission status: Accepted

Solution code:
s = input()
last = s[0]
flag = 0
for i in s[1:]:
    if i == last:
        flag = 1
    last = i

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

Submission status: Accepted

Solution code:
s = input()
for i in range(1,4):
    if s[i] == s[i-1]:
        print('Bad')
        exit()
print('Good')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=list(str(input()))
count=0
for i in range(3):
    if S[i]==S[i+1]:
        count+=1
    
if count==0:
    print('Good')
else:
    print('Bad')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()
list(S)
if S[0]==S[1]:
  result = 'Bad'
elif S[1]==S[2]:
  result ='Bad'
elif S[2]==S[3]:
  result='Bad'
else:
  result='Good'
print(result)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()

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

Submission status: Accepted

Solution code:
ls=list(input())
prev="hoge"

flag=True
for i in ls:
    if i==prev:
        print('Bad')
        flag=False
        break
    prev=i
if flag:
    print('Good')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
for i in range(len(s)-1):
	if s[i] == s[i+1]:
		print("Bad")
		break
else:
		print("Good")

Submission status: Accepted

Solution code:
def sec(N):
    tmp = N[0]
    for i in range(1, 4):
        if tmp == N[i]:
            print("Bad")
            return 0
        tmp = N[i]
    print("Good")


sec(input())

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = list(input())

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

Submission status: Accepted

Solution code:
s = str(input())
if 4 == len(s):
    if s[0] != s[1] and s[1] != s[2] and s[2] != s[3]:
        print('Good')
    else:
        print('Bad')
else:
    print('invalid value')

Submission status: Accepted

Solution code:
S=input();print("GBoaodd"[1^(S[0]!=S[1]!=S[2]!=S[3])::2])

Submission status: Accepted

Solution code:
s = input();print('GBoaodd'[any(s[i] == s[i+1] for i in range(3))::2])

Submission status: Accepted

Solution code:
a, b, c, d = map(int, list(input()))
if (a + b) / 2 == a:
  print('Bad')
elif (b + c) / 2 == b:
  print('Bad')
elif (c + d) / 2 == c:
  print('Bad')
else:
  print('Good')

Submission status: Accepted

Solution code:
S = input()
prev = S[0]
flag = 0
for s in S[1:]:
    if prev == s:
        print("Bad")
        flag = 1
        break
    prev = s
if flag == 0:
    print("Good")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def solve(l:list):
    flg = 0
    bef = "f"
    for i in l:
        if i == bef:
            flg += 1
        bef = i
    return flg > 0

def main():
    l = list(input())
    print("Bad") if solve(l) else print("Good")

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
S = input()

for i in range(1, 4):
    if S[i] == S[i-1]:
        print('Bad')
        exit()

print('Good')

Submission status: Accepted

Solution code:
str = int(input())

if ((int) (str / 1000) == (int) (str % 1000 / 100)) or ((int) (str % 1000 / 100) == (int) (str % 100 / 10)) or ((int) (str % 100 / 10) == (int) (str % 10)):
  print("Bad")
else:
  print("Good")

Submission status: Accepted

Solution code:
# coding:utf-8
s = str(input())

for i in range(3):
    #print(i)
    if s[i] == s[i+1]:
        print("Bad")
        break
    elif (s[2] != s[3] and i == 2):
        print("Good")
        break

Submission status: Accepted

Solution code:
s=list(input())

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

Submission status: Accepted

Solution code:
import sys
s = input()
letters = list(s)
flg = True
for i in range(len(letters)-1):
    if letters[i] == letters[i+1]:
        flg = False
        break
        
print("Good" if flg else "Bad")

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
matchNums=input()

flg=False
for i in range(len(matchNums)-1):
    if matchNums[i] == matchNums[i+1]:
        flg = True
if flg:
    print("Bad")
else:
    print("Good")

Submission status: Accepted

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