parse :: String -> [(Double , Double)]
parse xs = case read ("(" ++ xs ++ ")") of
    (xa,ya,xb,yb,xc,yc,xd,yd) -> [(xa,ya),(xb,yb),(xc,yc),(xd,yd)]

-- ???ABC???????§?????????????
isObtuseAngle :: (Double , Double) -> (Double , Double) -> Bool
isObtuseAngle ab bc = fst ba * snd bc - snd ba * fst bc < 0
    where
        ba = (negate $ fst ab , negate $ snd ab)

solve :: [(Double , Double)] -> IO ()
solve [a,b,c,d] = putStrLn $ maybe "NO" (const "YES") $
    foldr1 (\ (Just x) y -> case y of Just z -> if x == z then Just z else Nothing ; Nothing -> Nothing) $ map Just [isObtuseAngle da ab , isObtuseAngle ab bc , isObtuseAngle bc cd , isObtuseAngle cd da]
    where
        ab = (fst b - fst a , snd b - snd a)
        bc = (fst c - fst b , snd c - snd b)
        cd = (fst d - fst c , snd d - snd c)
        da = (fst a - fst d , snd a - snd d)
solve _ = undefined
    
main :: IO ()
main = getContents
    >>= mapM_ solve . map parse . lines