Determine the **area** of the largest square that can fit inside a circle with radius *r*.

Source: codewars | Difficulty: EASY
Tags: Geometry

Starter code: def area_largest_square(r):
	

Solutions:
def area_largest_square(r):
	return 2 * r ** 2


area_largest_square = lambda r: r * (r + r)


area_largest_square = lambda r: r * r * 2


import math

def area_largest_square(r):
	return 2 * r ** 2


def area_largest_square(r):
	diagonal = r * 2
	return diagonal ** 2 / 2


import math

def area_largest_square(r):
	d = 2 * r
	v = d ** 2
	l = math.sqrt(v)
	a = l * l / 2
	return a