#include<bits/stdc++.h>
#define dbug printf("I am here\n");
#define Fast ios_base::sync_with_stdio(false); cin.tie(0);
#define vs              v.size()
#define sot(v)        sort(v.begin(),v.end())
#define rev(v)        reverse(v.begin(),v.end())
#define ii                pair<int, int>
#define int              long long
#define ull              unsigned long long
#define pb              push_back
#define mpp          make_pair
#define Okay         0
#define pi               3.14159

const int inf = 1e6;
const int cont = 1e18;
using namespace std;

void solve(){
    int a, b, c, d;
    cin>>a>>b>>c>>d;
    cout<<max(a*b , b*c)<<endl;
}

int32_t main() {
    Fast;
    solve();
    return Okay;
}


#include <bits/stdc++.h>
using namespace std;
using pp=pair<int, int>;

int main() {
  int a, b, c, d;
  int>>a>>b>>c>>d;
  cout << max(a*b, c*d) << endl;
}


#include<iostream>
using namespace std;
int main()
{
  int A,B,C.D;
  cin>>A>>B>>C>>D;
  if(A*B>C*D){
    cout<<A*B;
  }
  else{
    cout<<C*D;
  }
}


#include <stdio.h>
#include <string.h>

int main(void)

{
	int a,b,c,d;
	scanf("%d %d %d %d",&a,&b,&c,&d);

	if(a*b>=c*d){
		printf("%d\n",a*b);
	} else{
		printf("%d\n",c*d);
	}
	return 0;
}


#include <stdio.h>

#define max(a, b) ((a) > (b) ? (a) : (b))

int main(void) {
	int a, b, c, d;

	scanf("%d %d %d %d", &a, &b, &c, &d);

	printf("%d\n", max(a * b, c * d));

	return 0;
}


#include <stdio.h>
int main(void){
 int a,b,c,d;
 scanf("%d %d %d %d",&a,&b,&c,&d);
 int e = a*b;
 int f = c*d;
 if(e>f) printf("%d",e);
 else printf("%d",f);
 return 0;
}


main(a,b,c,d){scanf("%d%d%d%d",&a,&b,&c,&d);printf("%g",fmax(a*b,c*d));}


#include <stdio.h>
int main()
{
    int a, b, c, d, i, f;
    scanf("%d %d %d %d", &a, &b, &c, &d);

    i = a*b;
    f = c*d;
    if(e>f)
    {
        printf("%d", i);
    }
    else
    {
        printf("%d", f);
    }
    return 0;
}


#include<stdio.h>
int main(){
  long long int a,b,c,d,area;
  scanf("%d %d %d %d\n",&a,&b,&c,&d);
  long long int area1,area2;
  area1 = a*b;
  area2 = c*d;
  if(area1>=area2) area = area1;
  else area =area2;
  printf("%lld\n",area);
  return 0;
}


'use strict'

const main = input => {
	const args = input.trim().split(' ').map(Number)
	console.log(Math.max(args[0] * args[1], args[2] * args[3]))
}

main(require('fs').readFileSync('/dev/stdin', 'utf8'))


var input = require('fs').readFileSync('/dev/stdin', 'utf8');
var inputArray = input.split(' ');
var a = inputArray[0];
var b = inputArray[1];
var c = inputArray[2];
var d = inputArray[3];

var result = (a * b > c * d) ? a * b : c * d;
console.log(result);


"use strict";

const main = arg => {
    const rectangles = arg.split("\n")[0].split(" ");
    const A = rectangles[0] * rectangles[1];
    const B = rectangles[2] * rectangles[3];
    console.log(Math.max(A, B));
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));


'use strict'

function main(input) {
  input = input.split('')
  const length = input[0]
  let res = 0;
  let list = [0];
  for (let i = 0;i < length;i++) {
    if (input[i + 2] == 'I') {
      res++;
    } else {
      res--;
    }
    list.push(res);
  }
  console.log(Math.max(...list));
}

main(require("fs").readFileSync("/dev/stdin", "utf8"));


inp = require('fs').readFileSync('/dev/stdin', 'utf8').split('\n')[0].split(' ')
A = inp.shift() * 1
B = inp.shift() * 1
C = inp.shift() * 1
D = inp.shift() * 1
console.log(A * B > B * C ? A * B : C * D)


"use strict";

const main = arg => {
    arg = arg.trim().split("\n");
    const N = parseInt(arg[0]);
    const MOD = 1e9 + 7;

    let cnt = [...Array(N + 1)].fill(0);

    for(let i=1; i<=N; i++) {
        let b = i;

        for(let j=2; j<=N; j++) {
            console.log("j:" + j);

            while(b % j === 0) {
                b /= j;
                cnt[j]++;
            }
        }
    }

    let answer = 1;

    for(let i=2; i<=N; i++) {
        answer = answer * (cnt[i] + 1) % MOD;
    }

    console.log(answer);
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));


package main

import (
	"bufio"
	"fmt"
	"math"
	"os"
	"reflect"
	"sort"
	"strconv"
	"strings"
	// "regexp"
)

/* sort */
type pair struct {
	index  int64
	p1, p2 interface{}
}
type pairs []pair

func (slice pairs) Len() int {
	return len(slice)
}

func (slice pairs) Less(i, j int) bool {
	return slice[i].index < slice[j].index
}

func (slice pairs) Swap(i, j int) {
	slice[i], slice[j] = slice[j], slice[i]
}

/* sort */
type Int64Slice []int64

func (slice Int64Slice) Len() int {
	return len(slice)
}

func (slice Int64Slice) Less(i, j int) bool {
	return slice[i] < slice[j]
}

func (slice Int64Slice) Swap(i, j int) {
	slice[i], slice[j] = slice[j], slice[i]
}
func Int64s(a []int64)                    { sort.Sort(Int64Slice(a)) }
func Int64sSliceAreSorted(a []int64) bool { return sort.IsSorted(Int64Slice(a)) }

const (
	initialBufSize = 1e4
	maxBufSize     = 1e8
	INF            = 1e8
)

var (
	scanner = bufio.NewScanner(os.Stdin)
	writer  = bufio.NewWriter(os.Stdout)
	di      = []int64{-1, 0, 1, 0}
	dj      = []int64{0, -1, 0, 1}
)

func main() {
	buf := make([]byte, initialBufSize)
	scanner.Buffer(buf, maxBufSize)
	scanner.Split(bufio.ScanWords)
	A, B, C, D := readInt(), readInt(), readInt(), readInt()
	fmt.Println(max(A*B, C*D))
}

/*==========================================
 *             Library
 *==========================================*/
func NextPermutation(x sort.Interface) bool {
	n := x.Len() - 1
	if n < 1 {
		return false
	}
	j := n - 1
	for ; !x.Less(j, j+1); j-- {
		if j == 0 {
			return false
		}
	}
	l := n
	for !x.Less(j, l) {
		l--
	}
	x.Swap(j, l)
	for k, l := j+1, n; k < l; {
		x.Swap(k, l)
		k++
		l--
	}
	return true
}
func doubleAry(h int64, w int64, init int64) (res [][]int64) {
	res = make([][]int64, h)
	for i := int64(0); i < h; i++ {
		res[i] = make([]int64, w)
		for j := int64(0); j < w; j++ {
			res[i][j] = init
		}
	}
	return
}

func aryEq(a []int64, b []int64) bool {
	return reflect.DeepEqual(a, b)
}

func clone(n []int64) (r []int64) {
	r = make([]int64, len(n))
	for i := 0; i < len(n); i++ {
		r[i] = n[i]
	}
	return
}
func write(s string) {
	writer.WriteString(s)
}

func print() {
	writer.Flush()
}

// scanner.Split(bufio.ScanWords) をコメントアウトしないと使用不可
func readLine() (s string) {
	if scanner.Scan() {
		s = scanner.Text()
	}
	return s
}

func readInt() (read int64) {
	scanner.Scan()
	read, err := strconv.ParseInt(scanner.Text(), 10, 64)
	if err != nil {
		panic(err)
	}
	return
}

func readFloat() (read float64) {
	scanner.Scan()
	read, err := strconv.ParseFloat(scanner.Text(), 64)
	if err != nil {
		panic(err)
	}
	return
}

func readRunes() (read []rune) {
	scanner.Scan()
	for _, v := range scanner.Text() {
		read = append(read, v)
	}
	return
}

func readString() (read string) {
	scanner.Scan()
	read = scanner.Text()
	return
}

func readStrings() (read []string) {
	scanner.Scan()
	for _, v := range scanner.Text() {
		read = append(read, string(v))
	}
	return
}

func s2i(s string) int64 {
	var intVal, e = strconv.ParseInt(s, 10, 64)
	if e != nil {
		panic(e)
	}
	return intVal
}

func i2s(i int64) string {
	var strVal = strconv.FormatInt(i, 10)
	return strVal
}

func s2f(s string) float64 {
	var floatVal, e = strconv.ParseFloat(s, 64)
	if e != nil {
		panic(e)
	}
	return floatVal
}

func abs(i int64) int64 {
	return int64(math.Abs(float64(i)))
}

func max(a ...int64) int64 {
	ans := int64(0)
	for i, v := range a {
		if i == 0 {
			ans = v
		}
		if ans < v {
			ans = v
		}
	}
	return ans
}
func min(a ...int64) int64 {
	ans := int64(0)
	for i, v := range a {
		if i == 0 {
			ans = v
		}
		if ans > v {
			ans = v
		}
	}
	return ans
}

func sum(i []int64) int64 {
	sum := int64(0)
	for _, val := range i {
		sum += val
	}
	return sum
}

func split(s string) []string {
	return strings.Fields(s)
}

func strAry2intAry(strs []string) []int64 {
	var ret = make([]int64, 0, len(strs))
	for _, str := range strs {
		var intVal = s2i(str)
		ret = append(ret, intVal)
	}
	return ret
}

func intAry2strAry(nums []int64) []string {
	var ret = make([]string, 0, len(nums))
	for _, num := range nums {
		var strVal = i2s(num)
		ret = append(ret, strVal)
	}
	return ret
}

func ary2str(strs []string) string {
	return strings.Join(strs, " ")
}

func reverse(res []int64) []int64 {
	for i, j := 0, len(res)-1; i < j; i, j = i+1, j-1 {
		res[i], res[j] = res[j], res[i]
	}
	return res
}
func reverseStr(res []string) []string {
	for i, j := 0, len(res)-1; i < j; i, j = i+1, j-1 {
		res[i], res[j] = res[j], res[i]
	}
	return res
}

func ini(res []int, init int) {
	if len(res) == 0 {
		return
	}
	res[0] = init
	for i := 0; i < len(res); i++ {
		copy(res[i:], res[:i])
	}
}

//
// func regexpExample() {
//     // Your code here!
//     var str = "13:20"
//     r := regexp.MustCompile(`(\d+):(\d+)`)
//     fmt.Println(r.FindStringSubmatch(str))
// }

// type Country struct {
//     gold int
//     silver int
//     blonze int
// }

// // 複数ソートのサンプル
// func stableSortExample() []Country{
//     var country = []Country {
//         {gold:1, silver:2, blonze:3},
//         {gold:1, silver:2, blonze:3},
//         {gold:1, silver:3, blonze:2},
//         {gold:1, silver:3, blonze:3},
//     }
//     sort.SliceStable(country, func(i, j int) bool { return country[i].blonze > country[j].blonze })
//     sort.SliceStable(country, func(i, j int) bool { return country[i].silver > country[j].silver })
//     sort.SliceStable(country, func(i, j int) bool { return country[i].gold > country[j].gold })
//     return country
// }


package main

import (
	"fmt"
)

func max(x, y int) int {
	if x >= y {
		return x
	}
	return y
}

func main() {
	var a, b, c, d int
	fmt.Scan(&a, &b, &c, &d)

	fmt.Println(max(a*b, c*d))
}


package main

import "fmt"

func max(x, y int) int {
	if x > y {
		return x
	}
	return y
}

func main() {
	var a, b, c, d int
	fmt.Scan(&a, &b, &c, &d)

	fmt.Println(max(a*b, c*d))
}


package main

import "fmt"

func main() {
	var (
		a, b, c, d, ab, cd int
	)

	fmt.Scan(&a)
	fmt.Scan(&b)
	fmt.Scan(&c)
	fmt.Scan(&d)

	ab = a * b
	cd = c * d

	if ab > cd {
		fmt.Print(ab)
	} else if ab < cd {
		fmt.Print(cd)
	} else {
		fmt.Print("error")
	}
}


package main

import (
	"fmt"
	"math"
)

func main() {
	// Code for A - Two Rectangles
	var A, B, C, D int
	fmt.Scanf("%d %d %d %d", &A, &B, &C, &D)
	fmt.Println(math.Max(float64(A*B), float64(C*D)))
}


package main

import (
  "fmt"
)

func main(){
  var a, b, c, d uint
  fmt.Scan(&a, &b, &c, &d)

  if a * b <= c * d {
    fmt.Print(c*d)
  }else if {
    fmt.Print(a*b)
  }
}


a,b,c,d = gets.split.map(&:to_i)
puts [a*b,c*d].max


a, b, c, d = gets.split(" ").map(&:to_i)
ab = a * b
cd = c * d
if ab > cd
  puts ab
elsif ab < cd
  puts cd
else
  puts ab
end


a, b, c, d = gets.split(" ").map(&:to_i)
p [a * b, c * d].max


a, b, c, d = gets().chomp.split("\s").map{|x| x.to_i}

r1 = a * b
r2 = c * d

if r1 > r2
  puts r1
else
  r2
end


a,b,c,d = gets.split.map(&:to_s)
puts [a*b,c*d].max


A, B, C, D = gets.split.map(&:to_i)

if A * B != C * D
  puts A * B
else
  puts [A * B, C * D].max
end


use std::io::*;
use std::str::FromStr;

pub fn read<T: FromStr>() -> T {
    let stdin = stdin();
    let stdin = stdin.lock();
    let token: String = stdin
        .bytes()
        .map(|c| c.expect("failed to read char") as char)
        .skip_while(|c| c.is_whitespace())
        .take_while(|c| !c.is_whitespace())
        .collect();
    token.parse().ok().expect("failed to parse token")
}

fn main() {
    let a: i64 = read();
    let b: i64 = read();
    let c: i64 = read();
    let d: i64 = read();

    if a * b < c * d {
        println!("{}", c * d);
    } else {
        println!("{}", a * b);
    }
}


use std::cmp::*;
use std::io::*;
use std::num::*;
use std::str::*;

fn read<T: FromStr>() -> T {
    let stdin = stdin();
    let s = stdin
        .bytes()
        .map(|c| c.unwrap() as char)
        .skip_while(|c| c.is_whitespace())
        .take_while(|c| !c.is_whitespace())
        .collect::<String>();
    s.parse::<T>().ok().unwrap()
}

fn string() -> String {
    read()
}

fn int() -> i64 {
    read()
}

fn char() -> char {
    read::<String>().pop().unwrap()
}

fn vecchar() -> Vec<char> {
    string().chars().collect()
}

fn vecint(n: i64) -> Vec<i64> {
    let mut vec = Vec::new();
    for i in 0..n {
        vec.push(int())
    }
    vec
}

fn main() {
    let (a, b, c, d) = (int(), int(), int(), int());
    println!("{}", max(a * b, c * d))
}


use std::io;
use std::cmp::max;

fn procon_read<T: std::str::FromStr>() ->  Vec<T> {
	let mut buf = String::new();
	io::stdin().read_line(&mut buf).expect("");
	let iter = buf.split_whitespace();
	let mut v: Vec<T> = Vec::new();
	for i in iter {
		v.push(i.parse().ok().unwrap());
	}
	v
}

fn main() {
	let v:Vec<i32> = procon_read();
	let a:i32 = v[0];
	let b:i32 = v[1];
	let c:i32 = v[2];
	let d:i32 = v[3];
	println!("{}", max(a*b, c*d));
}


use proconio::input;

use std::cmp::*;
// use std::collections::*;
// use proconio::marker::Chars;

fn main() {
    input! {
        // s: String
        a: i32,
        b: i32,
        c: i32,
        d: i32,
    }
    print("{}", max(a * b, c * d));
}


use core::cmp::max;
macro_rules! input {
    (source = $s:expr, $($r:tt)*) => {
        let mut iter = $s.split_whitespace();
        let mut next = || { iter.next().unwrap() };
        input_inner!{next, $($r)*}
    };
    ($($r:tt)*) => {
        let stdin = std::io::stdin();
        let mut bytes = std::io::Read::bytes(std::io::BufReader::new(stdin.lock()));
        let mut next = move || -> String{
            bytes
                .by_ref()
                .map(|r|r.unwrap() as char)
                .skip_while(|c|c.is_whitespace())
                .take_while(|c|!c.is_whitespace())
                .collect()
        };
        input_inner!{next, $($r)*}
    };
}

macro_rules! input_inner {
    ($next:expr) => {};
    ($next:expr, ) => {};

    ($next:expr, $var:ident : $t:tt $($r:tt)*) => {
        let $var = read_value!($next, $t);
        input_inner!{$next $($r)*}
    };
}

macro_rules! read_value {
    ($next:expr, ( $($t:tt),* )) => {
        ( $(read_value!($next, $t)),* )
    };

    ($next:expr, [ $t:tt ; $len:expr ]) => {
        (0..$len).map(|_| read_value!($next, $t)).collect::<Vec<_>>()
    };

    ($next:expr, chars) => {
        read_value!($next, String).chars().collect::<Vec<char>>()
    };

    ($next:expr, usize1) => {
        read_value!($next, usize) - 1
    };

    ($next:expr, $t:ty) => {
        $next().parse::<$t>().expect("Parse error")
    };
}

fn main() {
    input! {
        a:usize,
        b:usize,
        c:usize,
        d:usize,
    }
    let mut A = a * b;
    let mut B = c * d;
    println!("{}", max(A, B));
}


use std::vec::Vec;
use std::collections::HashMap;

fn read<T: std::str::FromStr>() -> T {
    let mut s = String::new();
    std::io::stdin().read_line(&mut s).ok();
    s.trim().parse().ok().unwrap()
}

fn read_vec<T: std::str::FromStr>() -> Vec<T> {
    read::<String>().split_whitespace().map(|e| e.parse().ok().unwrap()).collect()
}

fn read_touple<T: std::str::FromStr + Copy>() -> (T, T) {
  let v: Vec<T> = read_vec();
  assert_eq!(v.len(), 2);
  (v[0], v[1])
}

const MOD: usize = 1_000_000_000 + 7;

fn main() {
  let n: usize = read();
  let mut map = HashMap::new();
  let mut ans = 1;

  for i in 1..n+1 {
    let hash = trial_division(i);
    //println!("i = {} hash = {:?}",i,  hash);
    for (key, count) in hash.into_iter() {
      match map.get_mut(&key) {
          Some(x) => {
            *x += count;
          },
          _  => { map.insert(key, count); },
      }
    }
  }
  map.remove(&1);
  //println!("{:?}", map);
  for (key, count) in map.into_iter() {
    ans *= (count + 1);
    ans %= MOD;
  }
  println!("{}", ans);
}

// 試し割り
// O(√N)
fn trial_division(n :usize) -> HashMap<usize, usize>{
    let mut primes = HashMap::new();
    let mut i = 2;
    let mut n = n;

    //  n を root n 以下の整数で割り切れるまで割っていく
    while i * i <= n {
        while n % i == 0 {
            n /= i;
            // match primes.get_mut(&i) {
            //   None => { primes.insert(i, 1); },
            //   Some(x) => {
            //       *x += 1;
            //   },
            // }

            if let Some(x) = primes.get_mut(&i) {
              *x += 1;
            } else {
              primes.insert(i, 1);
            }
        }
        i+=1;
    }

    // 最後にnが素数になっている場合はそれ自身も素因数に含めて終了
    // match primes.get_mut(&n) {
    //   None => { primes.insert(n, 1); },
    //   Some(x) => {
    //     *x += 1;
    //   },
    // }

     if let Some(x) = primes.get_mut(&n) {
              *x += 1;
            } else {
              primes.insert(n, 1);
            }

    primes
}


let i=readLine()!.characters.split(" ").map{Int(String($0))!};print(max(i[0]*i[1],i[2]*i[3]))


let i=readLine()!.characters.split(" ").map{Int(String($0))!};print(max(i[0]*i[1],i[2],i[3]))


const stdin = require('fs').readFileSync('/dev/stdin', 'utf8')

const [a, b, c, d] = stdin
  .split('\n')[0]
  .split(' ')
  .map(Number)

console.log(a * b >= c * d ? a * b : c * d)


const main = (input) => {
  input = input.split(' ');
  const a = parseInt(input[0], 10);
  const b = parseInt(input[1], 10);
  const c = parseInt(input[2], 10);
  const d = parseInt(input[3], 10);

  if (a*b>=c*d) {
    console.log(a*b);
  }else if (a*b<=c*d){
    console.log(c*d);
  }else{
    console.log(a*b);
  }

}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));


const input=require('fs').readFileSync('/dev/stdin', 'utf8').split(/[\s]/);const nin=()=>{const r = input[0];input.shift();return Number(r)};const nrin=(n)=>{const a:number[]=[];rep(n,()=>a.push(nin()));return a};const sin=()=>{const r = input[0];input.shift();return String(r)};const out=(...a)=>{console.log(...a)};const floor=(a)=>{return Math.floor(a)};const abs=(a)=>{return Math.abs(a)};const min=(...a)=>{return Math.min(...a)};const max=(...a)=>{return Math.max(...a)};const rep=(n, callback)=>{for(let i = 0;i < n; i++){callback()}};const strrep=(s, i, v)=>{return s.slice(0, i)+v+s.slice(i+1);};const permutation=({result=[],pre=[],post,n=post.length})=>{if(n>0){post.forEach((_,i)=>{const rest=[...post];const elem=rest.splice(i, 1);permutation({result, pre: [...pre,...elem],post:rest,n:n-1})})}else{result.push(pre)}return result};const sw=(s,a:any[],op:'=='|'>='|'>'|'<='|'<'='==')=>{for(let i=0;i<a.length;i+=2){if(op==='=='){if(s==a[i])return a[i+1]}else if(op==='>='){if(s>=a[i])return a[i+1]}else if(op==='<='){if(s<=a[i])return a[i+1]}else if(op==='>'){if(s>a[i])return a[i+1]}else if(op==='<'){if(s<a[i])return a[i+1]}}return a[a.length-1];};const or=(a,...b)=>{for(let i=0;i<b.length;i++)if(a==b[i])return true;return false};const maxindex=(...a)=>{return a.indexOf(Math.max.apply(null,a))};const asc=(ar:number[])=>{return ar.sort((a,b)=>{return a-b})};const desc=(ar:number[])=>{return ar.sort((a,b)=>{return b-a})};const ceil=a=>{return Math.ceil(a)};const srin=s=>{const a:string[]=[];rep(s,()=>a.push(sin()));return a};let ssinteger=-1;const ssin=()=>{ssinteger++;return input[0][ssinteger]};
const main = ()=>{
  out(max(nin()*nin(),nin()*nin()))
}
main()


st main = (input) => {
  input = input.split(' ');
  const a = parseInt(input[0], 10);
  const b = parseInt(input[1], 10);
  const c = parseInt(input[2], 10);
  const d = parseInt(input[3], 10);

  if (a*b>=c*d) {
    console.log(a*b);
  }else if (a*b<=c*d){
    console.log(c*d);
  }else{
    console.log(a*b);
  }

}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));


const main = (input) => {
  input = input.split(' ');
  const a = parseInt(input[0], 10);
  const b = parseInt(input[1], 10);
  const c = parseInt(input[2], 10);
  const d = parseInt(input[3], 10);

  if (a*b>=c*d) {
    cosole.log(a*b);
  }else if (a*b<=c*d){
    cosole.log(c*d);
  }else{
    cosole.log(a*b);
  }

}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));


const main = (input) => {
  input = input.split(' ');
  const a = parseInt(input[0], 10);
  const b = parseInt(input[1], 10);
  const c = parseInt(input[2], 10);
  const d = parseInt(input[3], 10);

  if (a*b>c*d) {
    cosole.log(a*b);
  }else if (a*b<c*d){
    cosole.log(c*d);
  }else{
    cosole.log(a*b);
  }

}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));


N = int(input())

N3 = N//3
N5 = N//5
N15 = N//15

print(N*(N + 1)//2 - 3*N3*(N3 + 1)//2 - 5*N5*(N5 + 1)//2 + 15*N15*(N15 + 1)//2)


def resolve():
    n = int(input())
    def su(x): return x * (x + 1) // 2
    ans = 0
    ans += su(n // 3) * 3
    ans += su(n // 5) * 5
    ans -= su(n // 15) * 15
    ans = su(n) - ans
    print(ans)

if __name__ == '__main__':
    resolve()


#!/usr/bin/python3

def qsum(n, q):
    t = n // q
    return t * (q + q * t) // 2

n = int(input())

s = n * (n + 1) // 2
s -= qsum(n, 3)
s -= qsum(n, 5)
s += qsum(n, 15)

print(s)


N = int(input())
total = 0
for n in range(1, N+1):
  if N % 3 or N % 5:
    continue
  total += n
print(total)


N=int(input())
ans=0
for i in range(N+1):
  if i%3!=0 and a%5!=0:
    ans+=i
print(ans)


n=int(input())
a=[0]*n
for i in range(n):
    if i%3==0 or i%5==0:
        a[i]=0
    else:
        a[i]=i
print(sum(a))


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		long n = Long.parseLong(br.readLine());
		long sum = sum(n);
		long tsum = 3 * sum(n / 3);
		long fsum = 5 * sum(n / 5);
		long ffsum = 15 * sum(n / 15);
		System.out.println(sum - tsum - fsum + ffsum);
	}

	public static long sum(long n) {
		return (n * (n + 1)) / 2;
	}
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
    private static int MOD = 1000000007;

    public static void main(String[] args) throws IOException {
        InputStreamReader isr = new InputStreamReader(System.in);
        BufferedReader br = new BufferedReader(isr);
        String str = br.readLine();
        int n = Integer.parseInt(str);
        long total = 0;
        for (int i = 1; i <= n; i++) {
            if (i % 3 != 0 && i % 5 != 0) {
                total += i;
            }
        }
        System.out.println(total);
    }
}


/*****Author: Satyajeet Singh, Delhi Technological University************************************/
    import java.io.*;
    import java.util.*;
    import java.text.*;
    import java.lang.*;
    import java.math.*;
public class Main{
/*********************************************Constants******************************************/
    static PrintWriter out=new PrintWriter(new OutputStreamWriter(System.out));
    static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    static long mod=(long)1e9+7;
    static long mod1=998244353;
    static HashSet<Integer> graph[];
    static int pptr=0,pptrmax=0;
    static String st[];
/*****************************************Solutions Begins***************************************/
    public static void main(String args[]) throws Exception{
        int n=pi();
        long ans=0;
        for(int i=1;i<=n;i++){
            if(i%5==0||i%3==0)continue;
            ans+=i;
        }
        out.println(ans);
/****************************************Solutions Ends**************************************************/
        out.flush();
        out.close();
    }
/****************************************Template Begins************************************************/
    static void nl() throws Exception{
        pptr=0;
        st=br.readLine().split(" ");
        pptrmax=st.length;
    }
    static void nls() throws Exception{
        pptr=0;
        st=br.readLine().split("");
        pptrmax=st.length;
    }
    static int pi() throws Exception{
        if(pptr==pptrmax)
            nl();
        return Integer.parseInt(st[pptr++]);
    }
    static long pl() throws Exception{
        if(pptr==pptrmax)
            nl();
        return Long.parseLong(st[pptr++]);
    }
    static double pd() throws Exception{
        if(pptr==pptrmax)
            nl();
        return Double.parseDouble(st[pptr++]);
    }
    static String ps() throws Exception{
        if(pptr==pptrmax)
            nl();
        return st[pptr++];
    }
/***************************************Precision Printing**********************************************/
    static void printPrecision(double d){
        DecimalFormat ft = new DecimalFormat("0.000000000000");
        out.print(ft.format(d));
    }
/**************************************Bit Manipulation**************************************************/
    static void printMask(long mask){
        System.out.println(Long.toBinaryString(mask));
    }
    static int countBit(long mask){
        int ans=0;
        while(mask!=0){
            mask&=(mask-1);
            ans++;
        }
        return ans;
    }
/******************************************Graph*********************************************************/
    static void Makegraph(int n){
        graph=new HashSet[n];
        for(int i=0;i<n;i++){
            graph[i]=new HashSet<>();
        }
    }
    static void addEdge(int a,int b){
        graph[a].add(b);
    }
    // static void addEdge(int a,int b,int c){
    //     graph[a].add(new Pair(b,c));
    // }
/*********************************************PAIR********************************************************/
    static class Pair implements Comparable<Pair> {
        int u;
        int v;
        int index=-1;
        public Pair(int u, int v) {
            this.u = u;
            this.v = v;
        }
        public int hashCode() {
            int hu = (int) (u ^ (u >>> 32));
            int hv = (int) (v ^ (v >>> 32));
            return 31 * hu + hv;
        }
        public boolean equals(Object o) {
            Pair other = (Pair) o;
            return u == other.u && v == other.v;
        }
        public int compareTo(Pair other) {
            if(index!=other.index)
                return Long.compare(index, other.index);
            return Long.compare(v, other.v)!=0?Long.compare(v, other.v):Long.compare(u, other.u);
        }
        public String toString() {
            return "[u=" + u + ", v=" + v + "]";
        }
    }
/******************************************Long Pair*******************************************************/
    static class Pairl implements Comparable<Pairl> {
            long u;
            long v;
            int index=-1;
            public Pairl(long u, long v) {
                this.u = u;
                this.v = v;
            }
            public int hashCode() {
                int hu = (int) (u ^ (u >>> 32));
                int hv = (int) (v ^ (v >>> 32));
                return 31 * hu + hv;
            }
            public boolean equals(Object o) {
                Pairl other = (Pairl) o;
                return u == other.u && v == other.v;
            }
            public int compareTo(Pairl other) {
                if(index!=other.index)
                    return Long.compare(index, other.index);
                return Long.compare(v, other.v)!=0?Long.compare(v, other.v):Long.compare(u, other.u);
            }
            public String toString() {
                return "[u=" + u + ", v=" + v + "]";
            }
        }
/*****************************************DEBUG***********************************************************/
    public static void debug(Object... o){
        System.out.println(Arrays.deepToString(o));
    }
/************************************MODULAR EXPONENTIATION***********************************************/
    static long modulo(long a,long b,long c){
        long x=1;
        long y=a%c;
        while(b > 0){
            if(b%2 == 1)
                x=(x*y)%c;
            y = (y*y)%c;
            b /= 2;
        }
        return  x%c;
    }
/********************************************GCD**********************************************************/
    static long gcd(long x, long y){
        if(x==0)
            return y;
        if(y==0)
            return x;
        long r=0, a, b;
        a = (x > y) ? x : y;
        b = (x < y) ? x : y;
        r = b;
        while(a % b != 0){
            r = a % b;
            a = b;
            b = r;
        }
        return r;
    }
/********************************************End***********************************************************/
}


import java.util.*;
import java.io.*;
import java.lang.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int ans = 0;
        for (int i = 1; i<=n; i++){
            if ((i%3) != 0 && (i%5) != 0){
                ans += i;
            }
        }
        System.out.println(ans);
    }
}


import java.util.Scanner;

public class Main {
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int N=sc.nextInt();

    int a=N/3;
    int b=N/5;
    int c=N/15;

    int sumN=N*(N-1)/2;
    int suma=a*(a-1)/2;
    int sumb=b*(b-1)/2;
    int sumc=c*(c-1)/2;

    int X=sumN-3*suma-5*sumb+15*sumc;
    System.out.println(X);
  }
}


import java.util.Scanner;

public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();

        long sum = 0;
        for(int i = 1; i<a; i++){
            if(i % 3 != 0 && i % 5 != 0){
                sum += i;
            }
        }
        System.out.println(sum);
    }
}


#define _CRT_SECURE_NO_WARNINGS
#include<stdio.h>
#include<vector>
#include<functional>
#include<algorithm>
#include<stdlib.h>
#include<string>
#include<cmath>
#include<deque>
using namespace std;
typedef long long ll;
#define rep(i,a,b) for(int i=a;i<b;i++)
#define all(_x) _x.begin(), _x.end()
#define r_sort(_x) sort(_x.begin(), _x.end(), std::greater<int>())
#define INF 1LL << 60
#define MAX 1000000000
int main() {
	int N;
	ll s = 0;
	scanf("%d", &N);
	rep(i, 1, N + 1) {
		if (i % 3 && i % 5)s += i;
	}
	printf("%lld\n", s);
	return 0;
}


//
// Created by chuan on 2020-04-10.
//

#include <iostream>
#include <algorithm>
#include <set>
#include <string>
#include <vector>

using ll = long long;
using namespace std;
int main() {

    ll N; cin>>N;

    ll res{};

    ll s = (N+1)*N/2;
    for (ll i = 3; i <= N; i+=3) {
        s -= i;
    }
    for (ll i = 5; i <= N; i+=5) {
        s -= i;
    }

    for (ll i = 15; i <= N; i+=15) {
        s += i;
    }
    cout<<s<<endl;

    return 0;
}


#include <iostream>

using namespace std;

int main() {
    long long n;
    cin >> n;
    cout << n * (n + 1) / 2
            - (n / 3) * (3 * (n / 3) + 3) / 2
            - (n / 5) * (5 * (n / 5) + 5) / 2
            + (n / 15) * (15 * (n / 15) + 15) / 2 << endl;
}


#include <bits/stdc++.h>
using namespace std;
#define watch(x) cout << (#x) << " is " << (x) << '\n'
#define rep(i,a,n) for (int i=a;i<n;i++)
#define per(i,a,n) for (int i=n-1;i>=a;i--)
#define pb push_bacm
#define mp mame_pair
#define all(x) (x).begin(),(x).end()
#define fi first
#define se second
#define sz(x) ((int)(x).size())
typedef long long ll;
typedef vector<int> vi;
typedef vector<ll> vll;
typedef pair<int, int> pi;
typedef pair<ll, ll> pll;
typedef double db;
ll gcd(ll a, ll b) { return b?gcd(b,a%b):a; }
//head

void solve(){
    int n;
    cin >> n;
    int s = 0;
    for (int i = 1; i <= n; i++){
        if (i % 3 != 0 && i % 5 != 0) s += i;
    }
    cout << s << '\n';
}

int main(void){
    ios::sync_with_stdio(false);
    cin.tie(nullptr);
    cout.tie(nullptr);

    //int t; cin >> t; while (t--)
        solve();
}


#include<bits/stdc++.h>
using namespace std;

int main(){
  long N;
  scanf("%ld",N);
  long ans=0;
  for(long i=1;i<=N;i++){
    if(i%3!=0 && i%5!=0) ans+=i;
  }
  printf("%ld",ans);
}


#include <bits/stdc++.h>
#define rep(i,n) for (int i = 0; i < (n); ++i)
#define ALL(c) (c).begin(),(c).end()
using namespace std;
using ll = long long;
using P = pair<int,int>;
#define chmax(x,y) x = max(x,y)
#define chmin(x,y) x = min(x,y)

const int INF = 1e9 + 10;

int N;
int res = 0;

int main() {
    cin >> N;
    for (int i = 1; i <= N; ++i) {
        if (i%3==0 || i%5==0) continue;
        res += i;
    }
    cout << res << endl;
}


#include <stdio.h>

long long int sum (long long int n) {
    return n*(n+1)/2;
}

int main() {
    long long int N;
    scanf("%lld", &N);

    long long int ans;
    ans=sum(N)-3*sum(N/3)-5*sum(N/5)+15*sum(N/15);
    printf("%lld\n", ans);

    return 0;
}


#include<stdio.h>
int main(void){
  long int n,s,a,b,c,d,e,f,g;
  scanf("%ld", &n);
  s=(n*(n+1))/2;
  a=3*(n/3);
  b=5*(n/5);
  c=15*(n/15);
  d=((3+a)*(n/3))/2;
  e=((5+b)*(n/5))/2;
  f=((15+c)*(n/15))/2;
  g=s+f-d-e;
  printf("%ld", g);
  return 0;
}


#include <stdio.h>

int main(int argc, char const *argv[]) {

  long long int N;
  scanf("%lld", &N);

  long long int F, B, FB;
  F = N / 3;
  B = N / 5;
  FB = N / 15;

  long long int sum = N * (1 + N) / 2;
  sum = sum - ((3 + 3 * F) * F / 2) - ((5 + 5 * B) * B / 2) + (((15 + 15 * FB) * FB / 2));

  printf("%lld\n", sum);

  long long int A;
  return 0;
}


#include<algorithm>
#include<string.h>
#include<queue>
#include<math.h>
#include <iostream>
using namespace std;
///int a[1005];
int main()
{
   int n;
   cin>>n;
   long long sum=0;
   for(int i=1;i<=n;i++)
   {
    if(i%3==0||i%5==0)
        sum+=0;
    else
        sum+=i;
   }
    cout<<sum<<endl;
    return 0;
}


#include<stdio.h>
int main()
{
    int n;
    scanf ("%d",&n);
    long long int sum=0;
    for (int i=1;i<=n;i++)
    {
        if (i%3==0 )
        {
        }
        else if (i%5==0 )
        {

        }
        else if (i%3==0 && i%5==0)
        {

        }
        else
        {
            sum=sum+i;
        }
    }
    printf ("%I64d\n",sum);

}


#include<stdio.h>
int main()
{
    int n;
    scanf ("%d",&n);
    long long int sum=0;
    for (int i=1;i<=n;i++)
    {
        if (i%3==0 )
        {
        }
        else if (i%5==0 )
        {
        }
        else if (i%3==0 && i%5==0)
        {
        }
        else
        {
            sum=sum+i;
        }
    }
    printf ("%I64d",sum);

}


const main = input => {
  const n = parseInt(input)
  let r = 0;
  for (let i = 1; i <= n; i++) if (i % 3 != 0 && i % 5 != 0) r += i
  return r
}

console.log(main(require('fs').readFileSync('/dev/stdin', 'utf8')));


function Main (input) {
  let N = Number(input);
  let sum = 0;
  for(let i = 1; i < (N+1); i++){
      if((i % 3 !== 0) && (i % 5 !== 0)) {
        sum += i;
      }
  }
  console.log(sum);
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"));


function Main(input) {
    var N = parseInt(input,10);
    var sum = 0;
    for(var i=1;i<=N;i++){
        if(i%3 != 0 && i%5 !=0){
            //console.log(i);
            sum += i;
        }
    }
    console.log(sum);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));


// inputに入力データ全体が入る
function Main(input) {
	// 1行目がinput[0], 2行目がinput[1], …に入る
	var ans = 0
  input = input.trim().split("\n");
	const [N] = input[0].split(" ").map((n) => parseInt(n));
	for (i = 0; i < N; i++) {
		if (!(i % 5 == 0 || i % 3 == 0)) {
			ans = BigInt(ans) + BigInt(i)
		}
	}

  //出力
  console.log(ans.toString());
}
//*この行以降は編集しないでください（標準入出力から一度に読み込み、Mainを呼び出します）
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
// Main(require("fs").readFileSync("./input.txt", "utf-8"));


// inputに入力データ全体が入る
function Main(input) {
	// 1行目がinput[0], 2行目がinput[1], …に入る
	var ans = 0
  input = input.trim().split("\n");
	const [N] = input[0].split(" ").map((n) => parseInt(n));
	for (i = 0; i < N; i++) {
		if (!(i % 5 == 0 || i % 3 == 0)) {
			ans = ans +i
		}
	}

  //出力
  console.log(ans);
}
//*この行以降は編集しないでください（標準入出力から一度に読み込み、Mainを呼び出します）
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
// Main(require("fs").readFileSync("./input.txt", "utf-8"));


import java.io.*;

public class Main {
    public static void main (String[] args) throws Exception {
        BufferedReader reader =
            new BufferedReader (new InputStreamReader (System.in));
        long N = Long.parseLong (reader.readLine());
        System.out.println (calc (1, N) - calc (3, N) - calc (5, N) +
                            calc (15, N));
        return;
    }

    static long calc (long n, long N) {
        return (n + N / n * n) * (N / n) / 2;
    }
}


package main

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

func main() {
	nextReader = newScanner()
	n := nextInt()
	fmt.Println(sum(n) - sum(n/3)*3 - sum(n/5)*5 + sum(n/15)*15)
}

func sum(n int) int {
	return n * (n + 1) / 2
}

// ---------------------------------------------------------------
// I/O
// ---------------------------------------------------------------
var nextReader func() string

func newScanner() func() string {
	sc := bufio.NewScanner(os.Stdin)
	sc.Buffer(make([]byte, 1024), int(1e11))
	sc.Split(bufio.ScanWords)
	return func() string {
		sc.Scan()
		return sc.Text()
	}
}

func nextString() string { return nextReader() }

func nextInt() int { n, _ := strconv.Atoi(nextReader()); return n }

func nextInts(size int) []int {
	ns := make([]int, size)
	for i := 0; i < size; i++ {
		ns[i] = nextInt()
	}
	return ns
}


package main

import (
	"bufio"
	"fmt"
	"os"
	"strings"
)

func main() {
	// var input = StrStdin(1)

	// N, _ := strconv.Atoi(input[0][0])

	var N int
	fmt.Scanf("%d", &N)

	var fizz int = N / 3
	var bazz int = N / 5
	var fizzbazz int = N / 15

	var sum int = (1 + N) * N / 2
	var sumF int = 3 * (1 + fizz) * fizz / 2
	var sumB int = 5 * (1 + bazz) * bazz / 2
	var sumFB int = 15 * (1 + fizzbazz) * fizzbazz / 2

	// fmt.Printf("fizz:%d bazz:%d fizzbuzz:%d\n", fizz, bazz, fizzbazz)
	// fmt.Printf("sum:%d sumF:%d sumB:%d sumFB:%d\n", sum, sumF, sumB, sumFB)

	fmt.Println(sum - sumF - sumB + sumFB)
}

func StrStdin(num int) [][]string {
	var stringInput [][]string
	scanner := bufio.NewScanner(os.Stdin)

	for i := 0; i < num; i++ {
		scanner.Scan()
		if s := scanner.Text(); s != "" {
			stringInput = append(stringInput, strings.Split(strings.TrimSpace((scanner.Text())), " "))
		} else {
			break
		}
	}

	return stringInput
}


package main

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

func main() {
	var input = StrStdin(1)

	N, _ := strconv.Atoi(input[0][0])

	// var N int
	// fmt.Scanf("%d", &N)

	var fizz int = N / 3
	var bazz int = N / 5
	var fizzbazz int = N / 15

	var sum int = (1 + N) * N / 2
	var sumF int = 3 * (1 + fizz) * fizz / 2
	var sumB int = 5 * (1 + bazz) * bazz / 2
	var sumFB int = 15 * (1 + fizzbazz) * fizzbazz / 2

	fmt.Println(sum - sumF - sumB + sumFB)
}

func StrStdin(num int) [][]string {
	var stringInput [][]string
	scanner := bufio.NewScanner(os.Stdin)

	for i := 0; i < num; i++ {
		scanner.Scan()
		if s := scanner.Text(); s != "" {
			stringInput = append(stringInput, strings.Split(strings.TrimSpace((scanner.Text())), " "))
		} else {
			break
		}
	}

	return stringInput
}


package main

import "fmt"

func main() {
	var N int

	fmt.Scan(&N)

	answer := int64(0)
	for i := 0; i < N; i++ {
		if i%3 != 0 && i%5 != 0 {
			answer += int64(i)
		}
	}
	fmt.Println(answer)
}


package main

import "fmt"

func main() {
	var N int

	fmt.Scan(&N)

	answer := 0
	for i := 0; i < N; i++ {
		if i%3 != 0 && i%5 != 0 {
			answer += i
		}
	}
	fmt.Println(answer)
}


package main

import (
	"fmt"
)

func main() {

	var N int
	fmt.Scanf("%d", &N)

	var count int64
	count = 0

	for i := 0; i < N; i++ {
		if i%3 == 0 || i%5 == 0 {
			continue
		} else {
			count = count + int64(i)
		}
	}

	fmt.Println(count)
}


n = gets.to_i
c = n/15
m = n%15
arr = [0,1,2,0,4,0,0,7,8,0,0,11,0,13,14]
p 60*(c**2) + (m+1).times.map{|i| arr[i]!=0 ? (c*15+i) : 0}.sum


N = gets.to_i
n3 = N / 3
n5 = N / 5
n15 = N / 15

sn = N * (N + 1) / 2
s3n = 3 * n3 * (n3 + 1) / 2
s5n = 5 * n5 * (n5 + 1) / 2
s15n = 15 * n15 * (n15 + 1) / 2

puts sn - s3n - s5n + s15n


N = gets.to_i
a = N / 3
b = N / 5
c = N / 15

d = N * (1 + N) / 2
e = a * (3 + a * 3) / 2
f = b * (5 + b * 5) / 2
g = c * (15 + c * 15 ) / 2
puts d - e - f + g


a=0
(1..gets.to_i).each{|i|a+=i if i%3==0||i%5==0}
p a


N = gets.to_i
ans = 0
for i in 1...N+1 do
    if i%3==0 or i%5==0 then
        ans += i
    end
end
puts ans


package main

import (
	"fmt"
)

func main() {
	var n int
	fmt.Scan(&n)

	ans := 0
	for i := 1; i <= n; i++ {
		if !(i%5 == 0 || i%3 == 0) {
			ans += i
		}
	}
	fmt.Println(ans)
}


use proconio::input;
fn main() {
    input! {
        n: u64,
    }
    let f = |n| n*(n+1)/2;
    println!("{}",f(n)-f(n/3)*3-f(n/5)*5+f(n/15)*15);
}


use proconio::input;

fn main() {
    input! {
        n: u64
    }

    let ans = sum(n) - sum(n/3) * 3 - sum(n/5) * 5 + sum(n/15) * 15;

    println!("{}", ans);
}

fn sum(n: u64) -> u64 {
    n * (n+1) / 2
}


use proconio::input;

fn main() {
    input! {
        n: i64
    }
    let sum = |n| { n*(n+1)/2 };
    let ans = sum(n) - 3*sum(n/3) - 5*sum(n/5) + 15*sum(n/15);
    println!("{}", ans);
}


use proconio::{fastout, input};

#[fastout]
fn main() {
    input!(n: usize);
    let ans: usize = (0usize..n).filter(|x| x % 3 != 0 && x % 5 != 0).sum();

    println!("{}", ans);
}


// -*- coding:utf-8-unix -*-

use proconio::input;

fn main() {
    input! {
        n: u32,
    }

    let ans: u32 = (1..n + 1).filter(|i| i % 3 != 0 && i % 5 != 0).sum();
    println!("{}", ans);
}


// -*- coding:utf-8-unix -*-

use proconio::input;

fn main() {
    input! {
        n: u32,
    }

    let mut ans = 0;
    for i in 0..n + 1 {
        if i % 3 == 0 && i % 5 == 0 {
            ans += i;
        }
    }
    println!("{}", ans);
}


let a = Int(readLine()!)!
var j = 0
for i in 0...a
{
    if i%3 == 0&&i%5 == 0||i%3 == 0||i%5 == 0 {

    }else{
     j += i
    }
}

print(j)


func main() {
    var sum = 0;
    let N = Int(readLine()!)!
    for a in 1...N {
        if a % 3 > 0 && a % 5 > 0 {
            sum += a;
        }
    }
    print(sum)
}

main()


let n = Int(readLine()!)!
let result = (1...n).lazy.filter { $0 % 3 != 0 && $0 % 5 != 0 }.reduce(into: 0) { $0 += $1 }
print(result)


let N = Int(readLine()!) ?? 0
var total = 0
for i in 1...N{
  if i % 3 == 0 || i % 5 == 0{
  	total += i
  }
}
print(total)


import Foundation

let N = readLine()!
var sum = 0
for i in 1...15 {
	if i % 3 != 0 && i % 5 != 0 {
    	sum += i
    }
}
print(sum)


import Foundation

func readInt() -> [Int]{
    return readLine()!.split(separator: " ").map{Int($0)!}
}

func main() {
    let N = Int(readLine()!)!
    var ans = 0
    for i in 1...N {
        if i % 15 == 0 || i % 5 == 0 || i % 3 == 0 {
            ans += i
        }
    }

    print(ans)
}

main()


import { readFileSync } from "fs";

const quotient = (dividend: number, divisor: number): number =>
  Math.floor(dividend / divisor);

const summention = (n: number, step = 1): number => {
  const q = quotient(n, step);
  return step * ((q + 1) * quotient(q, 2) + (q % 2) * (quotient(q, 2) + 1));
};

export const solveB = (n: number): number =>
  summention(n) - summention(n, 3) - summention(n, 5) + summention(n, 15);

if (require.main === module)
  console.log(solveB(+readFileSync("/dev/stdin", "utf8")));


import * as fs from 'fs';

function Main(input: string) {
    const constraintN = parseInt(input, 10);

    let summ = 0;
    for (let i = 1; i <= constraintN; i++) {
        if (i % 3 !== 0 &&
            i % 5 !== 0) {
            summ += i;
            // console.log(`i=`, i);
        }
    }

    //output
    console.log(summ);
}

Main(fs.readFileSync('/dev/stdin', 'utf8'));


import * as fs from "fs";

const input = (fs.readFileSync("/dev/stdin", "utf8") as string).split("\n");
const n = +input[0];
let result = 0
for(let i=1;i<=n;i++){
	if(i%3===0 || i%5===0)continue;
	result+=i;
}

console.log(result);


class AtCoder {
  // 入力系
  input=require('fs').readFileSync('/dev/stdin','utf8').split(/[\s]/);
  input_i=-1;

  N=this.input[0];
  M=this.input[1];
  SN=String(this.input[0]);
  SM=String(this.input[1]);

  n(){
    this.input_i++;
    return Number(this.input[this.input_i]);
  }
  nn(n:number):number[]{
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.n());
    }
    return a;
  }
  s(){
    this.input_i++;
    return String(this.input[this.input_i]);
  }
  ss(n:number):string[]{
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.s());
    }
    return a;
  }

  // コンソール
  o(...a:any){
    console.log(...a);
  }

  // Math
  abs(a:number){
    return Math.abs(a);
  }
  min(...a:number[]){
    return Math.min(...a);
  }
  max(...a:number[]){
    return Math.max(...a);
  }
  floor(a:number){
    return Math.floor(a);
  }
  ceil(a:number){
    return Math.ceil(a);
  }
  round(a:number){
    return Math.round(a);
  }

  // ソート
  asc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return a-b});
  }
  desc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return b-a});
  }

  // 自作
  gcd(...arr:number[]):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=x;
    }
    return arr[arr.length-1];
  };
  lcm(...arr:number[]):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=arr[i]*arr[i+1]/x;
    }
    return arr[arr.length-1];
  };
  isPrime(n:number):boolean{
    if(n < 2) return false;
    const suq=Math.sqrt(n);
    for(let i=2;i<=suq;i++){
      if(n%i==0){
        return false;
      }
    }return true;
  };
  deduplicate(a:any[]):any[]{
    return Array.from(new Set(a));
  };
  f(roop:number, callback:any){
    for(let i=0;i<roop;i++){
      callback(i);
    }
  };
  Yes(){
    console.log('Yes');
  }
  No(){
    console.log('No');
  }
  YES(){
    console.log('YES');
  }
  NO(){
    console.log('NO');
  }
}
const m = () => {
  const o = new AtCoder()
  let g=0n;
  for(let i=0;i<o.N;i++){
    if(i % 3 == 0 || i % 5 == 0)continue
    g=BigInt(i) + g;
  }
  o.o(g.toString())
}
m();


class AtCoder {
  // 入力系
  input=require('fs').readFileSync('/dev/stdin','utf8').split(/[\s]/);
  input_i=-1;

  N=this.input[0];
  M=this.input[1];
  SN=String(this.input[0]);
  SM=String(this.input[1]);

  n(){
    this.input_i++;
    return Number(this.input[this.input_i]);
  }
  nn(n):number[]{
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.n());
    }
    return a;
  }
  s(){
    this.input_i++;
    return String(this.input[this.input_i]);
  }
  ss(n):string[]{
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.s());
    }
    return a;
  }

  // コンソール
  o(...a:any){
    console.log(...a);
  }

  // Math
  abs(a:number){
    return Math.abs(a);
  }
  min(...a:number[]){
    return Math.min(...a);
  }
  max(...a:number[]){
    return Math.max(...a);
  }
  floor(a:number){
    return Math.floor(a);
  }
  ceil(a:number){
    return Math.ceil(a);
  }
  round(a:number){
    return Math.round(a);
  }

  // ソート
  asc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return a-b});
  }
  desc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return b-a});
  }

  // 自作
  gcd(...arr):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=x;
    }
    return arr[arr.length-1];
  };
  lcm(...arr):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=arr[i]*arr[i+1]/x;
    }
    return arr[arr.length-1];
  };
  isPrime(n:number):boolean{
    if(n < 2) return false;
    const suq=Math.sqrt(n);
    for(let i=2;i<=suq;i++){
      if(n%i==0){
        return false;
      }
    }return true;
  };
  deduplicate(a:any[]):any[]{
    return Array.from(new Set(a));
  };
  f(roop, callback){
    for(let i=0;i<roop;i++){
      callback(i);
    }
  };
  Yes(){
    console.log('Yes');
  }
  No(){
    console.log('No');
  }
  YES(){
    console.log('YES');
  }
  NO(){
    console.log('NO');
  }
}
const main = () => {
  const o = new AtCoder()
  let g=0n;
  for(let i=0;i<o.N;i++){
    if(i % 3 == 0 || i % 5 == 0)continue
    g=BigInt(i) + g;
  }
  o.o(g)
}
main();


class AtCoder {
  // 入力系
  input=require('fs').readFileSync('/dev/stdin','utf8').split(/[\s]/);
  input_i=-1;

  N=this.input[0];
  M=this.input[1];
  SN=String(this.input[0]);
  SM=String(this.input[1]);

  n(){
    this.input_i++;
    return Number(this.input[this.input_i]);
  }
  nn(n):number[]{
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.n());
    }
    return a;
  }
  s(){
    this.input_i++;
    return String(this.input[this.input_i]);
  }
  ss(n):string[]{
    const a=[];
    for(let i=0;i<n;i++){
      a.push(this.s());
    }
    return a;
  }

  // コンソール
  o(...a:any){
    console.log(...a);
  }

  // Math
  abs(a:number){
    return Math.abs(a);
  }
  min(...a:number[]){
    return Math.min(...a);
  }
  max(...a:number[]){
    return Math.max(...a);
  }
  floor(a:number){
    return Math.floor(a);
  }
  ceil(a:number){
    return Math.ceil(a);
  }
  round(a:number){
    return Math.round(a);
  }

  // ソート
  asc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return a-b});
  }
  desc(ar:number[]){
    const t=[...ar];
    ar.sort((a,b)=>{return b-a});
  }

  // 自作
  gcd(...arr):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=x;
    }
    return arr[arr.length-1];
  };
  lcm(...arr):number{
    for(let i=0;i<arr.length-1;i++){
      let [x,y]=[arr[i],arr[i+1]];
      while(y){
        [x,y]=[y,x%y];
      }
      arr[i+1]=arr[i]*arr[i+1]/x;
    }
    return arr[arr.length-1];
  };
  isPrime(n:number):boolean{
    if(n < 2) return false;
    const suq=Math.sqrt(n);
    for(let i=2;i<=suq;i++){
      if(n%i==0){
        return false;
      }
    }return true;
  };
  deduplicate(a:any[]):any[]{
    return Array.from(new Set(a));
  };
  f(roop, callback){
    for(let i=0;i<roop;i++){
      callback(i);
    }
  };
  Yes(){
    console.log('Yes');
  }
  No(){
    console.log('No');
  }
  YES(){
    console.log('YES');
  }
  NO(){
    console.log('NO');
  }
}
const main = () => {
  const o = new AtCoder()
  let g=0
  for(let i=0;i<o.N;i++){
    if(i % 3 == 0 || i % 5 == 0)continue
    g+=i;
  }
  o.o(g)
}
main();


a,b=map(int,input().split())
print('Even' if a*b%2==0 else 'Odd')


#input
a,b = map(int,input().split())
#b = int(input())

#for i in range(K)
#	temp = temp
result = a*b

#output
if result%2 == 1:
  print('Odd')
else:
  print('Even')


#86a
a,b = map(int, input().split())
if a*b%2==0:
    print("Even")
else:
    print("Odd")


a, b = int(input())
print('Even' if a*b % 2 == 0 else 'Odd')


a,b = map(int,input(),split())
if a*b % 2 == 0:
    print("Even")
else:
    print("Odd")


a = map(int,input(),split())
if a*b % 2 == 0:
    print("Even")
else:
    print("Odd")


import java.util.*;
import java.io.*;

public class Main {
	public static void main(String []args)throws Exception{
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		String str=br.readLine();
		StringTokenizer st = new StringTokenizer(str);
		int a=Integer.parseInt(st.nextToken());
		int b=Integer.parseInt(st.nextToken());
		int c=a*b;
		if(c%2==0){
			System.out.print("Even");
		}else{
			System.out.print("Odd");
		}
	}

}


import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.InputMismatchException;
import java.util.NoSuchElementException;

public class Main {
	static PrintWriter out;
	static InputReader ir;

	static void solve() {
		long a = ir.nextLong();
		long b = ir.nextLong();
		out.println((a * b % 2 == 0) ? "Even" : "Odd");
	}

	public static void main(String[] args) {
		ir = new InputReader(System.in);
		out = new PrintWriter(System.out);
		solve();
		out.flush();
	}

	static class InputReader {

		private InputStream in;
		private byte[] buffer = new byte[1024];
		private int curbuf;
		private int lenbuf;

		public InputReader(InputStream in) {
			this.in = in;
			this.curbuf = this.lenbuf = 0;
		}

		public boolean hasNextByte() {
			if (curbuf >= lenbuf) {
				curbuf = 0;
				try {
					lenbuf = in.read(buffer);
				} catch (IOException e) {
					throw new InputMismatchException();
				}
				if (lenbuf <= 0)
					return false;
			}
			return true;
		}

		private int readByte() {
			if (hasNextByte())
				return buffer[curbuf++];
			else
				return -1;
		}

		private boolean isSpaceChar(int c) {
			return !(c >= 33 && c <= 126);
		}

		private void skip() {
			while (hasNextByte() && isSpaceChar(buffer[curbuf]))
				curbuf++;
		}

		public boolean hasNext() {
			skip();
			return hasNextByte();
		}

		public String next() {
			if (!hasNext())
				throw new NoSuchElementException();
			StringBuilder sb = new StringBuilder();
			int b = readByte();
			while (!isSpaceChar(b)) {
				sb.appendCodePoint(b);
				b = readByte();
			}
			return sb.toString();
		}

		public int nextInt() {
			if (!hasNext())
				throw new NoSuchElementException();
			int c = readByte();
			while (isSpaceChar(c))
				c = readByte();
			boolean minus = false;
			if (c == '-') {
				minus = true;
				c = readByte();
			}
			int res = 0;
			do {
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res = res * 10 + c - '0';
				c = readByte();
			} while (!isSpaceChar(c));
			return (minus) ? -res : res;
		}

		public long nextLong() {
			if (!hasNext())
				throw new NoSuchElementException();
			int c = readByte();
			while (isSpaceChar(c))
				c = readByte();
			boolean minus = false;
			if (c == '-') {
				minus = true;
				c = readByte();
			}
			long res = 0;
			do {
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res = res * 10 + c - '0';
				c = readByte();
			} while (!isSpaceChar(c));
			return (minus) ? -res : res;
		}

		public double nextDouble() {
			return Double.parseDouble(next());
		}

		public int[] nextIntArray(int n) {
			int[] a = new int[n];
			for (int i = 0; i < n; i++)
				a[i] = nextInt();
			return a;
		}

		public long[] nextLongArray(int n) {
			long[] a = new long[n];
			for (int i = 0; i < n; i++)
				a[i] = nextLong();
			return a;
		}

		public char[][] nextCharMap(int n, int m) {
			char[][] map = new char[n][m];
			for (int i = 0; i < n; i++)
				map[i] = next().toCharArray();
			return map;
		}
	}

	static void tr(Object... o) {
		out.println(Arrays.deepToString(o));
		out.flush();
	}
}


import java.io.*;
import java.util.*;
public class Main {

  public static void main (String args[]) throws Exception {

    if(oddEven() == 1) {
        System.out.println("Odd");
    } else {
        System.out.println("Even");
    }
  }

  public static int oddEven() throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line = br.readLine();
        StringTokenizer st;
        int prod = 0;
        String[] tmp = line.split(" ");
        prod = Integer.parseInt(tmp[0]) * Integer.parseInt(tmp[1]);

        return prod % 2;
  }

}


import java.util.*;
public class Main{
  public static void main(String[] args){
    Scanner sc=new Scanner(System.in);
    int a=sc.nextInt();
    int b=sc.nextInt();
    if((a*b)%2==0){
      System.out.println("Even");
    }else{
      System.out.printnln("Odd");
    }
  }
}


import java.util.*;
public class Main{
  public static void main(String[] args){
    Scanner sc=new Scanner(System.in);
    int a=sc.nextInt();
    int b=sc.nextInt();
    if((a*b)%2==0){
      Sytem.out.println("Even");
    }else{
      Sytem.out.printnln("Odd");
    }
  }
}


#include<stdio.h>
#include<math.h>
#include<algorithm>
#include<queue>
#include<deque>
#include<string>
#include<string.h>
#include<vector>
#include<set>
#include<map>
#include<bitset>
#include<stdlib.h>
#include<cassert>
#include<time.h>
#include<bitset>
using namespace std;
const long long mod=998244353;
const long long inf=mod*mod;
const long long d2=(mod+1)/2;
const double EPS=1e-6;
const double PI=acos(-1.0);
int ABS(int a){return max(a,-a);}
long long ABS(long long a){return max(a,-a);}

int main(){
	int a,b;scanf("%d%d",&a,&b);
	if(a*b%2)printf("Odd\n");else printf("Even\n");
}


#include<cstdio>
int main() {
	int a, b;
	scanf("%d%d", &a, &b);
	if ((a*b) % 2 == 0) {
		printf("Even");
	}
	else {
		printf("Odd");
	}
	return 0;
}


#define _CRT_SECURE_NO_WARNINGS
#include <cstdio>

using namespace std;

int main()
{
    int a, b;
    if (scanf("%d%d", &a, &b) < 2) return 0;

    printf("%s\n", a * b % 2 == 0 ? "Even" : "Odd");

    return 0;
}


#include <bits/stdc++.h>
using namespace std;

int main() {
  int a, b;
  cin << a << b;
  if ((a*b)%2==1) {
    cout << "odd" << endl;
  }
  else {
    cout << "even" << endl;
}


#include <bits/stdc++.h>

using namespace std;

int main() {

  int a, b;

  cin>> a >> b ;

int seki =a*b;
if (seki%2= 0) {
cout << "Even" << endl;

  }

  else if(seki%2=1){

    // ここにプログラムを追記

    cout<<"Odd"<<endl;

  }

  }


#include <bits/stdc++.h>
using namespace std;

int main() {
  int a, b;
  cin >> a >> b;
  int x = a * b;

  if (x % 2 == 0) {
    cout << "even" << endl;
  }
  else {
    cout << "odd" << endl;
  }
}


#include <stdio.h>

int main(void)
{
    int a,b;

    scanf("%d%d",&a,&b);

    if(a%2&&b%2)
        printf("Odd");
    else
        printf("Even");

    return 0;
}


#include <stdio.h>

int main(void) {
  int a, b;
  scanf("%d %d", &a, &b);
  if (a % 2 == 0 || b % 2 == 0) {
    printf("Even\n");
  } else {
    printf("Odd\n");
  }

  return 0;
}


#include <stdio.h>

int main(void){

  int data1, data2, seki;

  scanf("%d%d", &data1, &data2);

  seki = data1 * data2;

  if(seki % 2 == 0){
    printf("Even\n");
  } else {
    printf("Odd\n");
  }

  return 0;

}


#include<stdio.h>
int main(void) {
	int a, b;
	int s;
	scanf_s("%d %d", &a, &b);
	s = a * b;

	if (s % 2 == 0) {
		printf("Even\n");
	}
	else
		printf("Odd\n");

	return 0;
}


#include<stdio.h>
int main(void) {
	int a, b;
	int s;
	scanf_s("%d %d", &a, &b);
	s = a * b;

	if (s % 2 = 0) {
		printf("Even\n");
	}
	else
		printf("Odd\n");

	return 0;
}


function main(input) {
    const splitInput = input.split(' ');
    if((splitInput[0] * splitInput[1]) % 2 === 0) {
        //偶数
        console.log('Even');
    } else {
        //奇数
        console.log('Odd');
    }
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));


// inputに入力データ全体が入る
function Main(input) {
	// 1行目がinput[0], 2行目がinput[1], …に入る
	//input = input.split("\n");
	tmp = input.split(" ");
	//文字列から10進数に変換するときはparseIntを使います
	var a = parseInt(tmp[0], 10);
	var b = parseInt(tmp[1], 10);
	var output_string="";
	output_string= a * b % 2 == 0 ? "Even" : "Odd" ;
	//出力
	console.log(output_string);
}

//*この行以降は編集しないでください（標準入出力から一度に読み込み、Mainを呼び出します）
Main(require("fs").readFileSync("/dev/stdin", "utf8"));


function main (input) {
	const args = input.split(' ');
	const a = parseInt(args[0], 10);
	const b = parseInt(args[1], 10);

	if ((a * b) % 2 === 0) {
        console.log('Even');
    } else {
        console.log('Odd');
    }
}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));


function Main(input) {
  var input_splited = input.split(' ');
  var a = input_splited[0];
  var b = input_splited[1];
  var ab = a * b;
  if (ab % 2 == 0) {
    console.log('Even');
  } else {
    console.log('Odd');
  }
}


function main(input) {
  const inputs = input.split(' ');
  const T = inputs[0];
  const X = inputs[1];
  console.log(T / X);
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));


process.stdin.resume();
process.stdin.setEncoding('utf8');

var input_lines = [];
var reader = require('readline').createInterface({
  input: process.stdin,
  output: process.stdout
});

reader.on('line', (line) => {
  input_lines.push(parseInt(line));
});

if((input_lines[0]*input_lines[1]) % 2 === 0) console.log("Even");
else console.log("Odd");


package main

import (
        "fmt"
)

func main() {
        a := 0
        b := 0
        fmt.Scan(&a, &b)

        c := a * b
        if c%2 == 0 {
                fmt.Println("Even")
        } else {
                fmt.Println("Odd")
        }

}


package main

import(
    "fmt"
)

func main() {
    //入力
    var a,b int
    fmt.Scan(&a, &b)

    if a%2 == 0 || b%2 == 0{
        fmt.Println("Even")
    }else{
        fmt.Println("Odd")
    }
}


package main

import "fmt"

func main() {
	var a, b int
	fmt.Scan(&a, &b)
	if a*b%2 == 0 {
		fmt.Println("Even")
		return
	}
	fmt.Println("Odd")
}


package main

import "fmt"

func main() {
	var a, b int

	fmt.Scanf("%d\n", &a)

	fmt.Scanf("%d\n", &b)

	if a*b%2 == 0 {
		fmt.Println("Even")
	} else {
		fmt.Println("Odd")
	}

}


package main

import (
    "fmt"
)

func main() {
  var a,b int
  fmt.Scan(&a,&b)
  if a*b%==1{fmt.Println("Odd")}
  else{fmt.Println("Even")}
}


a,b = gets.chomp.split(" ").map(&:to_i)
c = a*b
if c.to_i.even?
  print("Even")
else
  print("Odd")
end


a,b = gets.split(" ").map(&:to_i)
if (a * b).even?
  print "Even"
else
  print "Odd"
end


a,b = gets.split().map(&:to_i)
puts a * b % 2 == 0 ? 'Even' : 'Odd'


a,b = gets.strip.split.map(&:to_i)
puts(a * b).odd? ? 'Odd' : 'Even'


a =get
puts a


a, b = gets.split(" ").to_i
if a * b % 2 == 0
  print('Even')
else
  print('Odd')
end


use proconio::input;

fn main() {
    input!{
        a: i32,
        b: i32,
    };
    let ans = if (a * b) % 2 == 0  {
        "Even"
    } else {
        "Odd"
    };
    println!("{}", ans);
}


/**
 * 標準入力マクロ by https://qiita.com/tanakh/items/0ba42c7ca36cd29d0ac8
 */
macro_rules! input {
    (source = $s:expr, $($r:tt)*) => {
        let mut iter = $s.split_whitespace();
        let mut next = || { iter.next().unwrap() };
        input_inner!{next, $($r)*}
    };
    ($($r:tt)*) => {
        let stdin = std::io::stdin();
        let mut bytes = std::io::Read::bytes(std::io::BufReader::new(stdin.lock()));
        let mut next = move || -> String{
            bytes
                .by_ref()
                .map(|r|r.unwrap() as char)
                .skip_while(|c|c.is_whitespace())
                .take_while(|c|!c.is_whitespace())
                .collect()
        };
        input_inner!{next, $($r)*}
    };
}

macro_rules! input_inner {
    ($next:expr) => {};
    ($next:expr, ) => {};

    ($next:expr, $var:ident : $t:tt $($r:tt)*) => {
        let $var = read_value!($next, $t);
        input_inner!{$next $($r)*}
    };
}

macro_rules! read_value {
    ($next:expr, ( $($t:tt),* )) => {
        ( $(read_value!($next, $t)),* )
    };

    ($next:expr, [ $t:tt ; $len:expr ]) => {
        (0..$len).map(|_| read_value!($next, $t)).collect::<Vec<_>>()
    };

    ($next:expr, chars) => {
        read_value!($next, String).chars().collect::<Vec<char>>()
    };

    ($next:expr, usize1) => {
        read_value!($next, usize) - 1
    };

    ($next:expr, $t:ty) => {
        $next().parse::<$t>().expect("Parse error")
    };
}

fn main() {
    input! {
        a: u32,
        b: u32,
    }
    println!("{}", if a * b % 2 == 0 { "Even" } else { "Odd" });
}


macro_rules! input {
    (source = $s:expr, $($r:tt)*) => {
        let mut iter = $s.split_whitespace();
        let mut next = || { iter.next().unwrap() };
        input_inner!{next, $($r)*}
    };
    ($($r:tt)*) => {
        let stdin = std::io::stdin();
        let mut bytes = std::io::Read::bytes(std::io::BufReader::new(stdin.lock()));
        let mut next = move || -> String{
            bytes
                .by_ref()
                .map(|r|r.unwrap() as char)
                .skip_while(|c|c.is_whitespace())
                .take_while(|c|!c.is_whitespace())
                .collect()
        };
        input_inner!{next, $($r)*}
    };
}

macro_rules! input_inner {
    ($next:expr) => {};
    ($next:expr, ) => {};

    ($next:expr, $var:ident : $t:tt $($r:tt)*) => {
        let $var = read_value!($next, $t);
        input_inner!{$next $($r)*}
    };
}

macro_rules! read_value {
    ($next:expr, ( $($t:tt),* )) => {
        ( $(read_value!($next, $t)),* )
    };

    ($next:expr, [ $t:tt ; $len:expr ]) => {
        (0..$len).map(|_| read_value!($next, $t)).collect::<Vec<_>>()
    };

    ($next:expr, chars) => {
        read_value!($next, String).chars().collect::<Vec<char>>()
    };

    ($next:expr, usize1) => {
        read_value!($next, usize) - 1
    };

    ($next:expr, $t:ty) => {
        $next().parse::<$t>().expect("Parse error")
    };
}
fn main() {
    input!{
        a: usize,
        b: usize,
    };

    let c = a * b;
    if c % 2 == 0{
        println!("Even");
        return;
    }
    println!("Odd");
}


fn main() {

    let mut s: String = read();
    s.retain(|c| c != ' ');
    let n: i32 = s.parse().unwrap();

    let mut sqrt_vec = Vec::new();
    for i in 1..1001 {
        sqrt_vec.push(i * i);
    }

    let mut flg: bool = true;

    for i in sqrt_vec {
        if i == n {
            println!("Yes");
            flg = false;
        }
    }

    if flg == true {
        println!("No");
    }
}

fn read<T: std::str::FromStr>() -> T {
    let mut s = String::new();
    std::io::stdin().read_line(&mut s).ok();
    s.trim().parse().ok().unwrap()
}

fn read_vec<T: std::str::FromStr>() -> Vec<T> {
    read::<String>()
        .split_whitespace()
        .map(|e| e.parse().ok().unwrap())
        .collect()
}

fn read_vec2<T: std::str::FromStr>(n: u32) -> Vec<Vec<T>> {
    (0..n).map(|_| read_vec()).collect()
}


fn main() {
    let a: i32 = read();
    let b: i32 = read();

    let ans = if (a * b) % 2 == 0 { "Even" } else { "Odd" };

    println!("{}", ans);
}

fn read<T: std::str::FromStr>() -> T {
    let mut s = String::new();
    std::io::stdin().read_line(&mut s).ok();
    s.trim().parse().ok().unwrap()
}


fn main() {

  	let a: i32 = read();
    let b: i32 = read();

    let ans = if (a * b) % 2 == 0 { "Even" } else { "Odd" };

    println!("{}", ans);
}

fn read<T: std::str::FromStr>() -> T {
    let mut s = String::new();
    std::io::stdin().read_line(&mut s).ok();
    s.trim().parse().ok().unwrap()
}


let arr = readLine()!.characters.split{$0 == " "}.map{Int(String($0))!}
let a = arr[0]
let b = arr[1]
print( (a * b) % 2 > 0 ? "Odd": "Even")


let arr = readLine()!.characters.split{$0 == " "}.map{Int(String($0))!}
let a = arr[0]
let b = arr[1]
print(a*b % 2 == 0 ? "Even": "Odd")


import Glibc
extension String: CollectionType {}

var inp = readLine()!.split(" ").map { Int($0)! }
if inp[0]*inp[1]%2==0 {
  print("Even")
} else {
  print("Odd")
}


let split = readLine()!.componentsSeparatedByString(" ")
let a = Int(split[0])!
let b = Int(split[1])!

if a*b%2==0{
    print("Even")
}else{
    print("Odd")
}


import Foundation

let input_line: String = readLine()!

let split: [String] = input_line.components(separatedBy: " ") //ブランクで区切られている場合

let a = Int(split[0])!
//String -> Intの型変換はnilが返る可能性があるので、ラップされたOptional<Int>型が返るので強制アンラップ
let b = Int(split[1])!

if a * b % 2 == 0{
    print("even")
}else{
    print("odd")
}


import Foundation

let input_line: String = readLine()!
let split: [String] = input_line.components(separatedBy: " ") //ブランクで区切られている場合

let a = Int(split[0])!
//String -> Intの型変換はnilが返る可能性があるので、ラップされたOptional<Int>型が返るので強制アンラップ
let b = Int(split[1])!

if a * b % 2 == 0{
    print("even")
}else{
    print("odd")
}


// inputに入力データ全体が入る
function Main(input) {
	// 1行目がinput[0], 2行目がinput[1], …に入る
	input = input.split("\n");
	let a = input[0].split(" ")[0];
	let b = input[0].split(" ")[1];
	//文字列から10進数に変換するときはparseIntを使います
  	if(a*b%2===0){
      console.log("Even");
    } else {
      console.log("Odd");
    }
}
//*この行以降は編集しないでください（標準入出力から一度に読み込み、Mainを呼び出します）
Main(require("fs").readFileSync("/dev/stdin", "utf8"));


function main(input) {
  const [a, b] = input.split(" ")
  const ans = (a * b) % 2 === 0 ? "Even" : "Odd"
  console.log(ans)
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));


const main = (input: void) => {
  const a: number = input.split(' ')[0];
  const b: number = input.split(' ')[1];

  if ( (a*b) % 2 === 0 ) {
    console.log('Even');
  } else {
    console.log('Odd');
  }
}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));


import * as fs from "fs";
const input = (fs.readFileSync("/dev/stdin", "utf8") as string)
  .split("\n")
  .map(Number);

console.log((input[0] - input[1]) % input[2]);


process.stdin.resume();
process.stdin.setEncoding('utf8');

let lines = [];
let reader = require('readline').createInterface({
  input: process.stdin,
  output: process.stdout
});
reader.on('line', (line) => {
  lines.push(line);
});
reader.on('close', () => {
  value=lines[0].split("")
  let sum=value[0]*value[1];
  if(sum%2===0) console.log("Even");
  else if(sum%3===0) console.log("Odd");

});


function Main(input) {
    input = input.split('\n');
    var [a,b] = input[0].split(' ').map(Number);
    console.log(a * b % 2 === 0 ? 'even' : 'odd');
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"));


a,b=input().split()
a=int(a)
b=list(b)
b=[int(b[0]),int(b[2]),int(b[3])]
c=(a*b[0]*100+a*b[1]*10+a*b[2])//100
print(c)


a,b = input().split()
a = int(a)
b = float(b)
val = int((b * 1000))
new = (a * val)//1000

#print(b)

print(new)


A, B = input().split()
A = int(A)
B = float(B)
B = round(B*100)
print(A * B//100)


#!/usr/bin/env python3

#import
#import math
#import numpy as np
#= int(input())
#= input()
A, B = map(float, input().split())
A = int(A)
B = int(B * 100)

print(A * B // 100)


import sys

def solve():
    readline = sys.stdin.buffer.readline
    mod = 10 ** 9 + 7
    a, b = list(map(float, readline().split()))
    print(int(a * b))

if __name__ == '__main__':
    solve()


A,B = input().split()
print((int(A)*int(100*float(B)))//100)


import java.util.*;
import java.io.*;
public class Main {

	public static void main(String[] args) throws Exception{
		int num = 998244353;

		// TODO Auto-generated method stub
 		BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
 		PrintWriter out = new PrintWriter(System.out);
 		StringTokenizer st = new StringTokenizer(bf.readLine());
 		long a = Long.parseLong(st.nextToken());
 		double b = Double.parseDouble(st.nextToken());
 		int c = (int)(b*100.0001);
 		long d = a*(long)(c);
 		out.println((d-((a%100)*(c%100))%100)/((long)(100)));
 		out.close();

 	}

}


import java.io.*;
import java.util.*;

public class Main {
	static void solve() {
		long a = nl();
		double b = nd();
		long e = (long)b;//整数部分
		double c = b - e + eps;//少数部分

		long d = (long)(c * 100);
		long t = a * d / 100;
		long ans =  a * ((long)b) + t;
		out.println(ans);
	}

	//constant
	static final int inf = Integer.MAX_VALUE / 2;
	static final long linf = Long.MAX_VALUE / 3;
	static final double dinf = Double.MAX_VALUE / 3;
	static final long mod = (long) 1e9 + 7;
	static final int dx[] = { -1, 0, 1, 0 }, dy[] = { 0, -1, 0, 1 };
	static final int[] dx8 = { -1, -1, -1, 0, 0, 1, 1, 1 }, dy8 = { -1, 0, 1, -1, 1, -1, 0, 1 };
	static final double eps = 1e-8;
	static final double pi = Math.PI;
	static StringBuilder sb = new StringBuilder();
	static InputStream is;
	static PrintWriter out;
	static String INPUT = "";

	//libraries
	static void reverse(int ar[]) {
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			int t = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = t;
		}
	}

	static void reverse(long ar[]) {
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			long t = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = t;
		}
	}

	static void reverse(double ar[]) {
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			double t = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = t;
		}
	}

	static void reverse(char ar[]) {
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			char t = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = t;
		}
	}

	static String getReverse(String s) {
		char c[] = s.toCharArray();
		reverse(c);
		s = String.valueOf(c);
		return s;
	}

	static <T> void reverse(List<T> ls) {
		int sz = ls.size();
		for (int i = 0; i < sz / 2; i++) {
			T t = ls.get(i);
			ls.set(i, ls.get(sz - 1 - i));
			ls.set(sz - 1 - i, t);
		}
	}

	static <T> void reverse(T[] ar) {
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			T t = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = t;
		}
	}

	static void sbnl() {//StringBuilderに改行文字をappendする
		sb.append("\n");
	}

	static int lowerBound(int[] a, int x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] < x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int upperBound(int[] a, int x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] <= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rlowerBound(int[] a, int x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] > x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rupperBound(int[] a, int x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] >= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int lowerBound(long[] a, long x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] < x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int upperBound(long[] a, long x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] <= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rlowerBound(long[] a, long x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] > x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rupperBound(long[] a, long x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] >= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int lowerBound(double[] a, double x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] < x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int upperBound(double[] a, double x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] <= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rlowerBound(double[] a, double x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] > x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rupperBound(double[] a, double x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] >= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int lowerBound(char[] a, char x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] < x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int upperBound(char[] a, char x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] <= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rlowerBound(char[] a, char x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] > x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static int rupperBound(char[] a, char x) {
		int l = -1, r = a.length;
		while (r - l > 1) {
			int c = (l + r) / 2;
			if (a[c] >= x) {
				l = c;
			} else {
				r = c;
			}
		}
		return r;
	}

	static <T> int lowerBound(List<T> ls, T x) throws RuntimeException {
		if (ls.size() == 0)
			return -1;
		if (ls.get(0) instanceof Integer) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Integer) t1).compareTo((Integer) t2) >= 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Long) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Long) t1).compareTo((Long) t2) >= 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Double) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Double) t1).compareTo((Double) t2) >= 0 ? 1 : -1);
		} else {
			System.err.println(
					String.format("%s:数値でないリストを二分探索しています。", Thread.currentThread().getStackTrace()[1].getMethodName()));
			throw new RuntimeException();
		}
	}

	static <T> int upperBound(List<T> ls, T x) throws RuntimeException {
		if (ls.size() == 0)
			return -1;
		if (ls.get(0) instanceof Integer) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Integer) t1).compareTo((Integer) t2) > 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Long) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Long) t1).compareTo((Long) t2) > 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Double) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Double) t1).compareTo((Double) t2) > 0 ? 1 : -1);
		} else {
			System.err.println(
					String.format("%s:数値でないリストを二分探索しています。", Thread.currentThread().getStackTrace()[1].getMethodName()));
			throw new RuntimeException();
		}
	}

	static <T> int rupperBound(List<T> ls, T x) throws RuntimeException {
		if (ls.size() == 0)
			return -1;
		if (ls.get(0) instanceof Integer) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Integer) t1).compareTo((Integer) t2) < 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Long) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Long) t1).compareTo((Long) t2) < 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Double) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Double) t1).compareTo((Double) t2) < 0 ? 1 : -1);
		} else {
			System.err.println(
					String.format("%s:数値でないリストを二分探索しています。", Thread.currentThread().getStackTrace()[1].getMethodName()));
			throw new RuntimeException();
		}
	}

	static <T> int rlowerBound(List<T> ls, T x) {
		if (ls.size() == 0)
			return -1;
		if (ls.get(0) instanceof Integer) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Integer) t1).compareTo((Integer) t2) <= 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Long) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Long) t1).compareTo((Long) t2) <= 0 ? 1 : -1);
		} else if (ls.get(0) instanceof Double) {
			return ~Collections.binarySearch(ls, x, (t1, t2) -> ((Double) t1).compareTo((Double) t2) <= 0 ? 1 : -1);
		} else {
			System.err.println(
					String.format("%s:数値でないリストを二分探索しています。", Thread.currentThread().getStackTrace()[1].getMethodName()));
			throw new RuntimeException();
		}
	}

	static int[] concat(int x, int arr[]) {
		int ret[] = new int[arr.length + 1];
		System.arraycopy(arr, 0, ret, 1, ret.length - 1);
		ret[0] = x;
		return ret;
	}

	static int[] concat(int arr[], int x) {
		int ret[] = new int[arr.length + 1];
		System.arraycopy(arr, 0, ret, 0, ret.length - 1);
		ret[ret.length - 1] = x;
		return ret;
	}

	static long[] concat(long x, long arr[]) {
		long ret[] = new long[arr.length + 1];
		System.arraycopy(arr, 0, ret, 1, ret.length - 1);
		ret[0] = x;
		return ret;
	}

	static long[] concat(long arr[], long x) {
		long ret[] = new long[arr.length + 1];
		System.arraycopy(arr, 0, ret, 0, ret.length - 1);
		ret[ret.length - 1] = x;
		return ret;
	}

	static char[] concat(char x, char arr[]) {
		char ret[] = new char[arr.length + 1];
		System.arraycopy(arr, 0, ret, 0, ret.length - 1);
		ret[ret.length - 1] = x;
		return ret;
	}

	static char[] concat(char arr[], char x) {
		char ret[] = new char[arr.length + 1];
		System.arraycopy(arr, 0, ret, 0, ret.length - 1);
		ret[ret.length - 1] = x;
		return ret;
	}

	static int max(int x, int y) {
		return Math.max(x, y);
	}

	static int min(int x, int y) {
		return Math.min(x, y);
	}

	static int max(int x, int y, int z) {
		x = Math.max(x, y);
		x = Math.max(x, z);
		return x;
	}

	static int min(int x, int y, int z) {
		x = Math.min(x, y);
		x = Math.min(x, z);
		return x;
	}

	static long max(long x, long y) {
		return Math.max(x, y);
	}

	static long min(long x, long y) {
		return Math.min(x, y);
	}

	static long max(long x, long y, long z) {
		x = Math.max(x, y);
		x = Math.max(x, z);
		return x;
	}

	static long min(long x, long y, long z) {
		x = Math.min(x, y);
		x = Math.min(x, z);
		return x;
	}

	static double max(double x, double y) {
		return Math.max(x, y);
	}

	static double min(double x, double y) {
		return Math.min(x, y);
	}

	static double max(double x, double y, double z) {
		x = Math.max(x, y);
		x = Math.max(x, z);
		return x;
	}

	static double min(double x, double y, double z) {
		x = Math.min(x, y);
		x = Math.min(x, z);
		return x;
	}

	static void sort(int[] ar) {
		Arrays.sort(ar);
	}

	static void sort(long[] ar) {
		Arrays.sort(ar);
	}

	static void sort(double[] ar) {
		Arrays.sort(ar);
	}

	static void sort(char[] ar) {
		Arrays.sort(ar);
	}

	static void rsort(int[] ar) {
		Arrays.sort(ar);
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			int tmp = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = tmp;
		}
	}

	static void rsort(long[] ar) {
		Arrays.sort(ar);
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			long tmp = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = tmp;
		}
	}

	static void rsort(double[] ar) {
		Arrays.sort(ar);
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			double tmp = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = tmp;
		}
	}

	static void rsort(char[] ar) {
		Arrays.sort(ar);
		int len = ar.length;
		for (int i = 0; i < len / 2; i++) {
			char tmp = ar[i];
			ar[i] = ar[len - 1 - i];
			ar[len - 1 - i] = tmp;
		}
	}

	static void fill(int arr[], int x) {
		Arrays.fill(arr, x);
	}

	static void fill(long arr[], long x) {
		Arrays.fill(arr, x);
	}

	static void fill(boolean arr[], boolean x) {
		Arrays.fill(arr, x);
	}

	static void fill(double arr[], double x) {
		Arrays.fill(arr, x);
	}

	static void fill(int arr[][], int x) {
		for (int i = 0; i < arr.length; i++)
			Arrays.fill(arr[i], x);
	}

	static void fill(long arr[][], long x) {
		for (int i = 0; i < arr.length; i++)
			Arrays.fill(arr[i], x);
	}

	static void fill(double arr[][], double x) {
		for (int i = 0; i < arr.length; i++)
			Arrays.fill(arr[i], x);
	}

	static void fill(boolean arr[][], boolean x) {
		for (int i = 0; i < arr.length; i++)
			Arrays.fill(arr[i], x);
	}

	//MOD culc
	static long plus(long x, long y) {
		long res = (x + y) % mod;
		return res < 0 ? res + mod : res;
	}

	static long sub(long x, long y) {
		long res = (x - y) % mod;
		return res < 0 ? res + mod : res;
	}

	static long mul(long x, long y) {
		long res = (x * y) % mod;
		return res < 0 ? res + mod : res;
	}

	static long div(long x, long y) {
		long res = x * pow(y, mod - 2) % mod;
		return res < 0 ? res + mod : res;
	}

	static long pow(long x, long y) {
		if (y < 0)
			return 0;
		if (y == 0)
			return 1;
		if (y % 2 == 1)
			return (x * pow(x, y - 1)) % mod;
		long root = pow(x, y / 2);
		return root * root % mod;
	}

	public static void main(String[] args) throws Exception {
		is = INPUT.isEmpty() ? System.in : new ByteArrayInputStream(INPUT.getBytes());
		out = new PrintWriter(System.out);
		solve();
		out.flush();
	}

	//input
	private static byte[] inbuf = new byte[1024];
	static int lenbuf = 0, ptrbuf = 0;

	private static int readByte() {
		if (lenbuf == -1)
			throw new InputMismatchException();
		if (ptrbuf >= lenbuf) {
			ptrbuf = 0;
			try {
				lenbuf = is.read(inbuf);
			} catch (IOException e) {
				throw new InputMismatchException();
			}
			if (lenbuf <= 0)
				return -1;
		}
		return inbuf[ptrbuf++];
	}

	private static boolean isSpaceChar(int c) {
		return !(c >= 33 && c <= 126);
	}

	private static int skip() {
		int b;
		while ((b = readByte()) != -1 && isSpaceChar(b))
			;
		return b;
	}

	@SuppressWarnings("unused")
	private static double nd() {
		return Double.parseDouble(ns());
	}

	@SuppressWarnings("unused")
	private static char nc() {
		return (char) skip();
	}

	private static String ns() {
		int b = skip();
		StringBuilder sb = new StringBuilder();
		while (!(isSpaceChar(b))) {
			sb.appendCodePoint(b);
			b = readByte();
		}
		return sb.toString();
	}

	private static char[] ns(int n) {
		char[] buf = new char[n];
		int b = skip(), p = 0;
		while (p < n && !(isSpaceChar(b))) {
			buf[p++] = (char) b;
			b = readByte();
		}
		return n == p ? buf : Arrays.copyOf(buf, p);
	}

	@SuppressWarnings("unused")
	private static char[][] nm(int n, int m) {
		char[][] map = new char[n][];
		for (int i = 0; i < n; i++)
			map[i] = ns(m);
		return map;
	}

	@SuppressWarnings("unused")
	private static int[] na(int n) {
		int[] a = new int[n];
		for (int i = 0; i < n; i++)
			a[i] = ni();
		return a;
	}

	@SuppressWarnings("unused")
	private static long[] nla(int n) {
		long[] a = new long[n];
		for (int i = 0; i < n; i++)
			a[i] = nl();
		return a;
	}

	private static int ni() {
		int num = 0, b;
		boolean minus = false;
		while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
			;
		if (b == '-') {
			minus = true;
			b = readByte();
		}

		while (true) {
			if (b >= '0' && b <= '9') {
				num = num * 10 + (b - '0');
			} else {
				return minus ? -num : num;
			}
			b = readByte();
		}
	}

	@SuppressWarnings("unused")
	private static long nl() {
		long num = 0;
		int b;
		boolean minus = false;
		while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
			;
		if (b == '-') {
			minus = true;
			b = readByte();
		}

		while (true) {
			if (b >= '0' && b <= '9') {
				num = num * 10 + (b - '0');
			} else {
				return minus ? -num : num;
			}
			b = readByte();
		}
	}

}


//master
import java.io.*;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.*;
public class Main {
    static int[][] memo;
    public static void main(String[] args) {
        FastScanner sc = new FastScanner();
        String a = sc.next();
        String b = sc.next();
        BigDecimal ba = new BigDecimal(a);
        BigDecimal bb = new BigDecimal(b);

        BigDecimal ans = ba.multiply(bb).setScale(0, RoundingMode.DOWN);
        p(ans);

    }

    public static <T> void p(T message) {
        System.out.println(message);
    }

    public static <T> void pe(T message) {
        System.err.println(message);
    }

    public static <T> void pp(T message) {
        System.out.print(message);
    }

}
class FastScanner {
    private final InputStream in = System.in;
    private final byte[] buffer = new byte[1024];
    private int ptr = 0;
    private int buflen = 0;
    private boolean hasNextByte() {
        if (ptr < buflen) {
            return true;
        } else {
            ptr = 0;
            try {
                buflen = in.read(buffer);
            } catch (IOException e) {
                e.printStackTrace();
            }
            if (buflen <= 0) {
                return false;
            }
        }
        return true;
    }

    private int readByte() {
        if (hasNextByte())
            return buffer[ptr++];
        else
            return -1;
    }

    private boolean isPrintableChar(int c) {
        return 33 <= c && c <= 126;
    }

    public boolean hasNext() {
        while (hasNextByte() && !isPrintableChar(buffer[ptr]))
            ptr++;
        return hasNextByte();
    }

    public String next() {
        if (!hasNext())
            throw new NoSuchElementException();
        StringBuilder sb = new StringBuilder();
        int b = readByte();
        while (isPrintableChar(b)) {
            sb.appendCodePoint(b);
            b = readByte();
        }
        return sb.toString();
    }

    public long nextLong() {
        if (!hasNext())
            throw new NoSuchElementException();
        long n = 0;
        boolean minus = false;
        int b = readByte();
        if (b == '-') {
            minus = true;
            b = readByte();
        }
        if (b < '0' || '9' < b) {
            throw new NumberFormatException();
        }
        while (true) {
            if ('0' <= b && b <= '9') {
                n *= 10;
                n += b - '0';
            } else if (b == -1 || !isPrintableChar(b)) {
                return minus ? -n : n;
            } else {
                throw new NumberFormatException();
            }
            b = readByte();
        }
    }

    public int nextInt() {
        long nl = nextLong();
        if (nl < Integer.MIN_VALUE || nl > Integer.MAX_VALUE)
            throw new NumberFormatException();
        return (int) nl;
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }
}


import java.util.Scanner;
public class Main{
    public static void main(String[] args) {
        Scanner stdIn= new Scanner(System.in);
        int a = stdIn.nextInt();
        double b = stdIn.nextDouble();
        double c=a*b;
        c=c-c%1;
        System.out.printf("%.0f",c);
    }
}