A - Shuffled Equation
Source: atcoder
Difficulty: 100

Problem Statement
You are given a sequence of integers
A = (A_1, A_2, A_3)
.
Let
B = (B_1, B_2, B_3)
be any permutation of
A
.
Determine whether it is possible that
B_1 \times B_2 = B_3
.
Constraints
All input values are integers.
1 \le A_1, A_2, A_3 \le 100
Input
The input is given from Standard Input in the following format:
A_1
A_2
A_3
Output
If it is possible that
B_1 \times B_2 = B_3
, print
Yes
; otherwise, print
No
.
Sample Input 1
3 15 5
Sample Output 1
Yes
Here,
A=(3,15,5)
.
By rearranging it as
B=(3,5,15)
, we can satisfy
B_1 \times B_2 = B_3
.
Sample Input 2
5 3 2
Sample Output 2
No
No permutation of
B
satisfies
B_1 \times B_2 = B_3
.

C++ solution:
#include <iostream>

int main() {
    // 入力
    long long A, B, C;
    std::cin >> A >> B >> C;

    // 条件チェック
    if (A * B == C || A * C == B || B * C == A) {
        std::cout << "Yes" << std::endl;
    } else {
        std::cout << "No" << std::endl;
    }

    return 0;
}

Go solution:
package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
)

var sc = bufio.NewScanner(os.Stdin)
var wtr = bufio.NewWriter(os.Stdout)

func scanInt() int {
	sc.Scan()
	i, e := strconv.Atoi(sc.Text())
	if e != nil {
		panic(e)
	}
	return i
}

func scanInts(n int) []int {
	ret := make([]int, n)
	for i := 0; i < n; i++ {
		ret[i] = scanInt()
	}
	return ret
}

func main() {
	// init
	sc.Split(bufio.ScanWords)
	var a []int = scanInts(3)
	if a[0]*a[1] == a[2] || a[0]*a[2] == a[1] || a[2]*a[1] == a[0] {
		fmt.Println("Yes")
		return
	} else {
		fmt.Println("No")
		return
	}
}

Java solution:
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class Main {
    public static void main(String[] args) throws IOException {
//        BufferedReader br = new BufferedReader(new FileReader("input.in"));
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st = new StringTokenizer(br.readLine());
        int sum = 0;
        int a = Integer.parseInt(st.nextToken());
        sum += a;
        int min = a;
        int max = a;
        a = Integer.parseInt(st.nextToken());
        sum += a;
        min = Math.min(a, min);
        max = Math.max(a, max);
        a = Integer.parseInt(st.nextToken());
        sum += a;
        min = Math.min(a, min);
        max = Math.max(a, max);

        if(max % min == 0 && sum - min - max == max / min) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    }
}

JavaScript solution:
const input = require('fs').readFileSync('/dev/stdin', 'utf-8').trim().split('\n');
const A = input[0].split(' ').map(Number);

A.sort((a, b) => a - b);

console.log(
    A[0] * A[1] === A[2] ? 'Yes' : 'No'
)

Python solution:
A = A = list(map(int, input().split()))
A.sort()

a = A[0]
b = A[1]
c = A[2]

if a*b == c:
    print("Yes")
else:
    print("No")

Ruby solution:
a, b, c = gets.split(' ').map(&:to_i)

if a * b == c
  puts "Yes"
elsif b * c == a
  puts "Yes"
elsif c * a == b
  puts "Yes"
else
  puts "No"
end