-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
67 lines (67 loc) · 4.27 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Arbitrage Calculator</title>
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/tailwind.min.css" rel="stylesheet">
<style>
.hidden { display: none; }
</style>
</head>
<body class="bg-gray-100 flex items-center justify-center min-h-screen">
<div class="bg-white p-8 rounded-lg shadow-lg w-full max-w-md">
<div class="mb-6 p-4 bg-blue-100 rounded-md shadow-md">
<h1 class="text-3xl font-bold mb-4 text-center text-blue-600">Arbitrage Calculator</h1>
<div class="text-center text-gray-600">
<p class="font-semibold">Instructions:</p>
<ol class="list-decimal list-inside text-left mx-auto text-sm">
<li>Select the number of odds (2 or 3).</li>
<li>Enter the odds values and the total investment amount.</li>
<li>Click "Calculate" to see the arbitrage opportunity, percentage, optimal stakes, total returns, and guaranteed profit.</li>
</ol>
</div>
</div>
<div class="space-y-4">
<div class="input-group">
<label for="numOdds" class="block text-sm font-medium text-gray-700">Number of Odds:</label>
<select id="numOdds" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" onchange="toggleOddsFields()">
<option value="2">2</option>
<option value="3">3</option>
</select>
</div>
<div class="input-group">
<label for="odds1Win" class="block text-sm font-medium text-gray-700">Win Site 1:</label>
<input type="number" id="odds1Win" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" step="0.01" placeholder="Enter Win Site 1 odds">
</div>
<div class="input-group">
<label for="odds1Lost" class="block text-sm font-medium text-gray-700">Lost Site 1:</label>
<input type="number" id="odds1Lost" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" step="0.01" placeholder="Enter Lost Site 1 odds">
</div>
<div class="input-group">
<label for="odds2Win" class="block text-sm font-medium text-gray-700">Win Site 2:</label>
<input type="number" id="odds2Win" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" step="0.01" placeholder="Enter Win Site 2 odds">
</div>
<div class="input-group">
<label for="odds2Lost" class="block text-sm font-medium text-gray-700">Lost Site 2:</label>
<input type="number" id="odds2Lost" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" step="0.01" placeholder="Enter Lost Site 2 odds">
</div>
<div class="input-group hidden" id="odds3Win-container">
<label for="odds3Win" class="block text-sm font-medium text-gray-700">Draw Site 1:</label>
<input type="number" id="odds3Win" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" step="0.01" placeholder="Enter Draw Site 1 odds">
</div>
<div class="input-group hidden" id="odds3Lost-container">
<label for="odds3Lost" class="block text-sm font-medium text-gray-700">Draw Site 2:</label>
<input type="number" id="odds3Lost" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" step="0.01" placeholder="Enter Draw Site 2 odds">
</div>
<div class="input-group">
<label for="investment" class="block text-sm font-medium text-gray-700">Total Investment:</label>
<input type="number" id="investment" class="mt-1 block w-full rounded-md border-gray-300 shadow-sm" step="0.01" placeholder="Enter total investment">
</div>
<button onclick="calculateArbitrage()" class="w-full py-2 px-4 bg-blue-600 text-white rounded-md shadow hover:bg-blue-700 focus:outline-none">Calculate</button>
</div>
<div id="results" class="mt-6 p-4 bg-gray-100 rounded-md shadow-md text-gray-700"></div>
</div>
<script src="script.js"></script>
</body>
</html>