跳到主要内容
图灵 OJTURING / ONLINE JUDGE

#F2095. The Great Game

  • ID: 2101
  • 传统题
  • 2000ms
  • 256MiB
  • 尝试: 0
  • AC · 已通过: 0
  • 教学难度:进阶
  • 上传者:
  • 待分类
  • 整理状态
  • 进阶
  • 难度
  • 共享题库
  • Codeforces
  • 英文题面
  • 题目来源
  • 题面语言

The Great Game

题目描述

A. The Great Game
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

Two teams meet in The Game World Championship. Some scientists consider this game to be the most intellectually challenging game in the world. You are given two strings describing the teams' actions in the final battle. Figure out who became the champion.

Input

The input contains two strings of equal length (between 2 and 20 characters, inclusive). Each line describes the actions of one team.

Output

Output "TEAM 1 WINS" if the first team won, "TEAM 2 WINS" if the second team won, and "TIE" if there was a tie.

Examples
Input
[]()[]8<
8<[]()8<
Output
TEAM 2 WINS
Input
8<8<()
[]8<[]
Output
TIE

题目来源:fps-www.educg.net-codeforce-1-2833.xml.zip;FPS 共享题包,题包内第 1691 题。保留原作者与原赛事署名。