0% found this document useful (0 votes)
7 views46 pages

Codeforces Handle Change Guide

Uploaded by

smbrn07
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views46 pages

Codeforces Handle Change Guide

Uploaded by

smbrn07
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.

01//EN">
<!-- saved from
url=(0092)[Link]
contest/580643/problem/B -->
<html lang="en"><head><meta http-equiv="Content-Type" content="text/html;
charset=UTF-8">

<meta name="X-Csrf-Token" content="f9d86a46f7d81154b506431c5e7ca8f2">


<meta id="viewport" name="viewport" content="width=device-width, initial-
scale=0.01">

<script type="text/javascript" src="./Problem - B -


Codeforces.htxt_files/[Link]"></script>
<script type="application/javascript">
[Link] = "en";
[Link] = true;
function adjustViewport() {
var screenWidthPx = [Link]($(window).width(), [Link]);
var siteWidthPx = 1100; // min width of site
var ratio = [Link](screenWidthPx / siteWidthPx, 1.0);
var viewport = "width=device-width, initial-scale=" + ratio;
$('#viewport').attr('content', viewport);
var style = $('<style>html * { max-height: 1000000px; }</style>');
$('html > head').append(style);
}

if ( /Android|webOS|iPhone|iPad|iPod|BlackBerry/[Link]([Link])
) {
adjustViewport();
}

/* Protection against trailing dot in domain. */


let hostLength = [Link];
if (hostLength > 1 && [Link][hostLength - 1] === '.') {
[Link] = [Link] + "//" +
[Link](0, hostLength - 1);
}
</script>

<meta http-equiv="pragma" content="no-cache">


<meta http-equiv="expires" content="-1">
<meta http-equiv="profileName" content="i1">
<meta name="google-site-verification"
content="OTd2dN5x4nS4OPknPI9JFg36fKxjqY0i1PSfFPv_J90">
<meta property="fb:admins" content="100001352546622">
<meta property="og:image" content="/static/images/codeforces-sponsored-by-
[Link]">
<link rel="image_src" href="./Problem - B - Codeforces.htxt_files/codeforces-
[Link]">
<meta property="og:title" content="Problem - B - Codeforces">
<meta property="og:description" content="">

<meta property="og:site_name" content="Codeforces">


<meta name="uc" content="bbf5df271a119f389742ab757f9e934fe9e4c813">
<meta name="usmc" content="ea971a6e24ab015018a0fbfcd7e427c8030f19ec">

<meta name="cc" content="8e0175d04e9237a4d26ffbb4cae0bbda18cea4ba">


<meta name="pc" content="12d8ab0397f52e1aafe9d2bd2af976fa3c5d1ffe">
<meta name="utc_offset" content="+03:00">
<meta name="verify-reformal" content="f56f99fd7e087fb6ccb48ef2">
<title>Problem - B - Codeforces</title>
<meta name="description" content="Codeforces. Programming competitions and
contests, programming community">
<meta name="keywords" content="programming algorithm contest competition
informatics olympiads c++ java graphs vkcup">
<meta name="robots" content="index, follow">

<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/font-


[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/line-
[Link]" type="text/css" charset="utf-8">

<link rel="apple-touch-icon" sizes="57x57"


href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="60x60"
href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="72x72"
href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="76x76"
href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="114x114"
href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="120x120"
href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="144x144"
href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="152x152"
href="[Link]
[Link]">
<link rel="apple-touch-icon" sizes="180x180"
href="[Link]
[Link]">
<link rel="icon" type="image/png" sizes="192x192"
href="[Link]
[Link]">
<link rel="icon" type="image/png" sizes="32x32"
href="[Link]
<link rel="icon" type="image/png" sizes="96x96"
href="[Link]
<link rel="icon" type="image/png" sizes="16x16"
href="[Link]
<link rel="manifest"
href="[Link]
<meta name="msapplication-TileColor" content="#ffffff">
<meta name="msapplication-TileImage" content="/static/[Link]">
<meta name="theme-color" content="#ffffff">
<!--CombineResourcesFilter-->
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/[Link]"
type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/[Link]"
type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/problem-
[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/second-
[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/table-
[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/[Link]"
type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/[Link]"
type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B - Codeforces.htxt_files/sidebar-
[Link]" type="text/css" charset="utf-8">

<!-- MathJax -->


<script type="text/x-mathjax-config;executed=true">
[Link]({
tex2jax: {inlineMath: [['$$$','$$$']], displayMath: [['$$$$$$','$$$$$$']]}
});
[Link]("End", function () {
[Link]();
});
</script>
<script type="text/javascript" async="" src="./Problem - B -
Codeforces.htxt_files/[Link]">
</script>
<!-- /MathJax -->

<script type="text/javascript" src="./Problem - B -


Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<!--/CombineResourcesFilter-->

<link rel="stylesheet" href="./Problem - B -


Codeforces.htxt_files/style(1).css" type="text/css" charset="utf-8">
<link rel="stylesheet" href="./Problem - B -
Codeforces.htxt_files/style(2).css" type="text/css" charset="utf-8">
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>
<script type="text/javascript" src="./Problem - B -
Codeforces.htxt_files/[Link]"></script>

<!--[if IE]>
<style>
#sidebar {
padding-left: 1em;
margin: 1em 1em 1em 0;
}
</style>
<![endif]-->

<script id="[Link]-builds/[Link]" src="./Problem - B -


Codeforces.htxt_files/[Link]" type="text/javascript"></script><style
id="ace_editor.css">.ace_editor {position: relative;overflow: hidden;font:
12px/normal 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro',
monospace;direction: ltr;}.ace_scroller {position: absolute;overflow: hidden;top:
0;bottom: 0;background-color: inherit;-ms-user-select: none;-moz-user-select:
none;-webkit-user-select: none;user-select: none;cursor: text;}.ace_content
{position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-
sizing: border-box;min-width: 100%;}.ace_dragging .ace_scroller:before{position:
absolute;top: 0;left: 0;right: 0;bottom: 0;content: '';background: rgba(250, 250,
250, 0.01);z-index: 1000;}.ace_dragging.ace_dark .ace_scroller:before{background:
rgba(0, 0, 0, 0.01);}.ace_selecting, .ace_selecting * {cursor: text !
important;}.ace_gutter {position: absolute;overflow : hidden;width: auto;top:
0;bottom: 0;left: 0;cursor: default;z-index: 4;-ms-user-select: none;-moz-user-
select: none;-webkit-user-select: none;user-select: none;}.ace_gutter-active-line
{position: absolute;left: 0;right: 0;}.ace_scroller.ace_scroll-left {box-shadow:
17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;}.ace_gutter-cell {padding-left:
19px;padding-right: 6px;background-repeat: no-repeat;}.ace_gutter-cell.ace_error
{background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/
////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/
SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/
gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/
SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/
Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/
QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/
GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/
eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/
v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/
9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTti
pwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8
ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/
chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-
position: 2px center;}.ace_gutter-cell.ace_warning {background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX/
//8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/
rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/
zHAAAAA9Nir/tFIAAAD/tlTiuWf/
tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hT
f4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/
z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/
SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS+
+NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");background-position: 2px center;}.ace_gutter-
cell.ace_info {background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRT
b2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiL
znjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK
5CYII=");background-position: 2px center;}.ace_dark .ace_gutter-cell.ace_info
{background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUA
AAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNp
jYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");}.ace_s
crollbar {position: absolute;right: 0;bottom: 0;z-index: 6;}.ace_scrollbar-inner
{position: absolute;cursor: text;left: 0;top: 0;}.ace_scrollbar-v{overflow-x:
hidden;overflow-y: scroll;top: 0;}.ace_scrollbar-h {overflow-x: scroll;overflow-y:
hidden;left: 0;}.ace_print-margin {position: absolute;height: 100%;}.ace_text-input
{position: absolute;z-index: 0;width: 0.5em;height: 1em;opacity: 0;background:
transparent;-moz-appearance: none;appearance: none;border: none;resize:
none;outline: none;overflow: hidden;font: inherit;padding: 0 1px;margin: 0 -
1px;text-indent: -1em;-ms-user-select: text;-moz-user-select: text;-webkit-user-
select: text;user-select: text;white-space: pre!important;}.ace_text-
input.ace_composition {background: inherit;color: inherit;z-index: 1000;opacity:
1;text-indent: 0;}.ace_layer {z-index: 1;position: absolute;overflow: hidden;word-
wrap: normal;white-space: pre;height: 100%;width: 100%;-moz-box-sizing: border-
box;-webkit-box-sizing: border-box;box-sizing: border-box;pointer-events:
none;}.ace_gutter-layer {position: relative;width: auto;text-align: right;pointer-
events: auto;}.ace_text-layer {font: inherit !important;}.ace_cjk {display: inline-
block;text-align: center;}.ace_cursor-layer {z-index: 4;}.ace_cursor {z-index:
4;position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-
box;box-sizing: border-box;border-left: 2px solid;transform:
translatez(0);}.ace_slim-cursors .ace_cursor {border-left-width:
1px;}.ace_overwrite-cursors .ace_cursor {border-left-width: 0;border-bottom: 1px
solid;}.ace_hidden-cursors .ace_cursor {opacity: 0.2;}.ace_smooth-
blinking .ace_cursor {-webkit-transition: opacity 0.18s;transition: opacity
0.18s;}.ace_editor.ace_multiselect .ace_cursor {border-left-width:
1px;}.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {position:
absolute;z-index: 3;}.ace_marker-layer .ace_selection {position: absolute;z-index:
5;}.ace_marker-layer .ace_bracket {position: absolute;z-index: 6;}.ace_marker-layer
.ace_active-line {position: absolute;z-index: 2;}.ace_marker-layer .ace_selected-
word {position: absolute;z-index: 4;-moz-box-sizing: border-box;-webkit-box-sizing:
border-box;box-sizing: border-box;}.ace_line .ace_fold {-moz-box-sizing: border-
box;-webkit-box-sizing: border-box;box-sizing: border-box;display: inline-
block;height: 11px;margin-top: -2px;vertical-align: middle;background-
image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGX
RFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//
PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQ
ikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/
0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvg
nYAAAAASUVORK5CYII="),url("data:image/
png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9i
ZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//
fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");background-repeat:
no-repeat, repeat-x;background-position: center center, top left;color:
transparent;border: 1px solid black;border-radius: 2px;cursor: pointer;pointer-
events: auto;}.ace_dark .ace_fold {}.ace_fold:hover{background-
image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGX
RFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//
PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQ
ikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/
0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvg
nYAAAAASUVORK5CYII="),url("data:image/
png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9i
ZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//
fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");}.ace_tooltip
{background-color: #FFF;background-image: -webkit-linear-gradient(top, transparent,
rgba(0, 0, 0, 0.1));background-image: linear-gradient(to bottom, transparent,
rgba(0, 0, 0, 0.1));border: 1px solid gray;border-radius: 1px;box-shadow: 0 1px 2px
rgba(0, 0, 0, 0.3);color: black;max-width: 100%;padding: 3px 4px;position: fixed;z-
index: 999999;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-
sizing: border-box;cursor: default;white-space: pre;word-wrap: break-word;line-
height: normal;font-style: normal;font-weight: normal;letter-spacing:
normal;pointer-events: none;}.ace_folding-enabled > .ace_gutter-cell {padding-
right: 13px;}.ace_fold-widget {-moz-box-sizing: border-box;-webkit-box-sizing:
border-box;box-sizing: border-box;margin: 0 -12px 0 1px;display: none;width:
11px;vertical-align: top;background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR4
2mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5
ErkJggg==");background-repeat: no-repeat;background-position: center;border-radius:
3px;border: 1px solid transparent;cursor: pointer;}.ace_folding-enabled .ace_fold-
widget {display: inline-block; }.ace_fold-widget.ace_end {background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR4
2m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5
ErkJggg==");}.ace_fold-widget.ace_closed {background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR4
2jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAA
AAElFTkSuQmCCXA==");}.ace_fold-widget:hover {border: 1px solid rgba(0, 0, 0,
0.3);background-color: rgba(255, 255, 255, 0.2);box-shadow: 0 1px 1px rgba(255,
255, 255, 0.7);}.ace_fold-widget:active {border: 1px solid rgba(0, 0, 0,
0.4);background-color: rgba(0, 0, 0, 0.05);box-shadow: 0 1px 1px rgba(255, 255,
255, 0.8);}.ace_dark .ace_fold-widget {background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQI
W2P4//8/
AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");}.ace_dark .ace_fold-
widget.ace_end {background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQI
W2P4//8/
AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-
widget.ace_closed
{background-image:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQI
W2P4//+/
AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-
widget:hover {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);background-color:
rgba(255, 255, 255, 0.1);}.ace_dark .ace_fold-widget:active {box-shadow: 0 1px 1px
rgba(255, 255, 255, 0.2);}.ace_fold-widget.ace_invalid {background-color:
#FFB4B4;border-color: #DE5555;}.ace_fade-fold-widgets .ace_fold-widget {-webkit-
transition: opacity 0.4s ease 0.05s;transition: opacity 0.4s ease 0.05s;opacity:
0;}.ace_fade-fold-widgets:hover .ace_fold-widget {-webkit-transition: opacity 0.05s
ease 0.05s;transition: opacity 0.05s ease 0.05s;opacity:1;}.ace_underline {text-
decoration: underline;}.ace_bold {font-weight: bold;}.ace_nobold .ace_bold {font-
weight: normal;}.ace_italic {font-style: italic;}.ace_error-marker {background-
color: rgba(255, 0, 0,0.2);position: absolute;z-index: 9;}.ace_highlight-marker
{background-color: rgba(255, 255, 0,0.2);position: absolute;z-index: 8;}.ace_br1
{border-top-left-radius : 3px;}.ace_br2 {border-top-right-radius :
3px;}.ace_br3 {border-top-left-radius : 3px; border-top-right-radius:
3px;}.ace_br4 {border-bottom-right-radius: 3px;}.ace_br5 {border-top-left-radius
: 3px; border-bottom-right-radius: 3px;}.ace_br6 {border-top-right-radius : 3px;
border-bottom-right-radius: 3px;}.ace_br7 {border-top-left-radius : 3px; border-
top-right-radius: 3px; border-bottom-right-radius: 3px;}.ace_br8 {border-bottom-
left-radius : 3px;}.ace_br9 {border-top-left-radius : 3px; border-bottom-left-
radius: 3px;}.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius:
3px;}.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px;
border-bottom-left-radius: 3px;}.ace_br12{border-bottom-right-radius: 3px; border-
bottom-left-radius: 3px;}.ace_br13{border-top-left-radius : 3px; border-bottom-
right-radius: 3px; border-bottom-left-radius: 3px;}.ace_br14{border-top-right-
radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius:
3px;}.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px;
border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}
/*# sourceURL=ace/css/ace_editor.css */</style><style id="ace-tm">.ace-
tm .ace_gutter {background: #f0f0f0;color: #333;}.ace-tm .ace_print-margin {width:
1px;background: #e8e8e8;}.ace-tm .ace_fold {background-color: #6B72E6;}.ace-tm
{background-color: #FFFFFF;color: black;}.ace-tm .ace_cursor {color: black;}.ace-tm
.ace_invisible {color: rgb(191, 191, 191);}.ace-tm .ace_storage,.ace-
tm .ace_keyword {color: blue;}.ace-tm .ace_constant {color: rgb(197, 6, 11);}.ace-
tm .ace_constant.ace_buildin {color: rgb(88, 72, 246);}.ace-
tm .ace_constant.ace_language {color: rgb(88, 92, 246);}.ace-
tm .ace_constant.ace_library {color: rgb(6, 150, 14);}.ace-tm .ace_invalid
{background-color: rgba(255, 0, 0, 0.1);color: red;}.ace-
tm .ace_support.ace_function {color: rgb(60, 76, 114);}.ace-
tm .ace_support.ace_constant {color: rgb(6, 150, 14);}.ace-
tm .ace_support.ace_type,.ace-tm .ace_support.ace_class {color: rgb(109, 121,
222);}.ace-tm .ace_keyword.ace_operator {color: rgb(104, 118, 135);}.ace-
tm .ace_string {color: rgb(3, 106, 7);}.ace-tm .ace_comment {color: rgb(76, 136,
107);}.ace-tm .ace_comment.ace_doc {color: rgb(0, 102, 255);}.ace-
tm .ace_comment.ace_doc.ace_tag {color: rgb(128, 159, 191);}.ace-
tm .ace_constant.ace_numeric {color: rgb(0, 0, 205);}.ace-tm .ace_variable {color:
rgb(49, 132, 149);}.ace-tm .ace_xml-pe {color: rgb(104, 104, 91);}.ace-
tm .ace_entity.ace_name.ace_function {color: #0000A2;}.ace-tm .ace_heading {color:
rgb(12, 7, 255);}.ace-tm .ace_list {color:rgb(185, 6, 144);}.ace-
tm .ace_meta.ace_tag {color:rgb(0, 22, 142);}.ace-tm .ace_string.ace_regex {color:
rgb(255, 0, 0)}.ace-tm .ace_marker-layer .ace_selection {background: rgb(181, 213,
255);}.ace-tm.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px
white;}.ace-tm .ace_marker-layer .ace_step {background: rgb(252, 255, 0);}.ace-
tm .ace_marker-layer .ace_stack {background: rgb(164, 229, 101);}.ace-
tm .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgb(192,
192, 192);}.ace-tm .ace_marker-layer .ace_active-line {background: rgba(0, 0, 0,
0.07);}.ace-tm .ace_gutter-active-line {background-color : #dcdcdc;}.ace-
tm .ace_marker-layer .ace_selected-word {background: rgb(250, 250, 255);border: 1px
solid rgb(200, 200, 250);}.ace-tm .ace_indent-guide {background:
url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQI
mWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;}
/*# sourceURL=ace/css/ace-tm */</style><style> .error_widget_wrapper
{ background: inherit; color: inherit;
border:none } .error_widget { border-top: solid 2px; border-
bottom: solid 2px; margin: 5px 0; padding: 10px 40px; white-
space: pre-wrap; } .error_widget.ace_error, .error_widget_arrow.ace_error{
border-color:
#ff5a5a } .error_widget.ace_warning, .error_widget_arrow.ace_warning{
border-color: #F1D817 } .error_widget.ace_info, .error_widget_arrow.ace_info{
border-color: #5a5a5a } .error_widget.ace_ok, .error_widget_arrow.ace_ok{
border-color: #5aaa5a } .error_widget_arrow { position: absolute;
border: solid 5px; border-top-color: transparent!important; border-
right-color: transparent!important; border-left-color: transparent!
important; top: -5px; }</style>
<script id="[Link]-builds/ext-language_tools.js" src="./Problem - B -
Codeforces.htxt_files/ext-language_tools.[Link]"
type="text/javascript"></script><style>.ace_snippet-marker { -moz-box-sizing:
border-box; box-sizing: border-box; background: rgba(194, 193, 208, 0.09);
border: 1px dotted rgba(211, 208, 235, 0.62); position:
absolute;}</style><style>.ace_editor.ace_autocomplete .ace_marker-
layer .ace_active-line { background-color: #CAD6FA; z-index:
1;}.ace_editor.ace_autocomplete .ace_line-hover { border: 1px solid #abbffe;
margin-top: -1px; background:
rgba(233,233,253,0.4);}.ace_editor.ace_autocomplete .ace_line-hover { position:
absolute; z-index: 2;}.ace_editor.ace_autocomplete .ace_scroller { background:
none; border: none; box-shadow: none;}.ace_rightAlignedText { color: gray;
display: inline-block; position: absolute; right: 4px; text-align: right;
z-index: -1;}.ace_editor.ace_autocomplete .ace_completion-highlight{ color:
#000; text-shadow: 0 0 0.01em;}.ace_editor.ace_autocomplete { width: 280px;
z-index: 200000; background: #fbfbfb; color: #444; border: 1px lightgray
solid; position: fixed; box-shadow: 2px 3px 5px rgba(0,0,0,.2); line-
height: 1.4;}</style>
<script id="[Link]-builds/[Link]" src="./Problem - B -
Codeforces.htxt_files/[Link]" type="text/javascript"></script>

<style type="text/css">.MathJax_Hover_Frame {border-radius: .25em; -webkit-border-


radius: .25em; -moz-border-radius: .25em; -khtml-border-radius: .25em; box-shadow:
0px 0px 15px #83A; -webkit-box-shadow: 0px 0px 15px #83A; -moz-box-shadow: 0px 0px
15px #83A; -khtml-box-shadow: 0px 0px 15px #83A; border: 1px solid #A6D !
important; display: inline-block; position: absolute}
.MathJax_Menu_Button .MathJax_Hover_Arrow {position: absolute; cursor: pointer;
display: inline-block; border: 2px solid #AAA; border-radius: 4px; -webkit-border-
radius: 4px; -moz-border-radius: 4px; -khtml-border-radius: 4px; font-family:
'Courier New',Courier; font-size: 9px; color: #F0F0F0}
.MathJax_Menu_Button .MathJax_Hover_Arrow span {display: block; background-color:
#AAA; border: 1px solid; border-radius: 3px; line-height: 0; padding: 4px}
.MathJax_Hover_Arrow:hover {color: white!important; border: 2px solid #CCC!
important}
.MathJax_Hover_Arrow:hover span {background-color: #CCC!important}
</style><style type="text/css">#MathJax_About {position: fixed; left: 50%; width:
auto; text-align: center; border: 3px outset; padding: 1em 2em; background-color:
#DDDDDD; color: black; cursor: default; font-family: message-box; font-size: 120%;
font-style: normal; text-indent: 0; text-transform: none; line-height: normal;
letter-spacing: normal; word-spacing: normal; word-wrap: normal; white-space:
nowrap; float: none; z-index: 201; border-radius: 15px; -webkit-border-radius:
15px; -moz-border-radius: 15px; -khtml-border-radius: 15px; box-shadow: 0px 10px
20px #808080; -webkit-box-shadow: 0px 10px 20px #808080; -moz-box-shadow: 0px 10px
20px #808080; -khtml-box-shadow: 0px 10px 20px #808080; filter:
progid:[Link](OffX=2, OffY=2, Color='gray',
Positive='true')}
#MathJax_About.MathJax_MousePost {outline: none}
.MathJax_Menu {position: absolute; background-color: white; color: black; width:
auto; padding: 2px; border: 1px solid #CCCCCC; margin: 0; cursor: default; font:
menu; text-align: left; text-indent: 0; text-transform: none; line-height: normal;
letter-spacing: normal; word-spacing: normal; word-wrap: normal; white-space:
nowrap; float: none; z-index: 201; box-shadow: 0px 10px 20px #808080; -webkit-box-
shadow: 0px 10px 20px #808080; -moz-box-shadow: 0px 10px 20px #808080; -khtml-box-
shadow: 0px 10px 20px #808080; filter:
progid:[Link](OffX=2, OffY=2, Color='gray',
Positive='true')}
.MathJax_MenuItem {padding: 2px 2em; background: transparent}
.MathJax_MenuArrow {position: absolute; right: .5em; padding-top: .25em; color:
#666666; font-size: .75em}
.MathJax_MenuActive .MathJax_MenuArrow {color: white}
.MathJax_MenuArrow.RTL {left: .5em; right: auto}
.MathJax_MenuCheck {position: absolute; left: .7em}
.MathJax_MenuCheck.RTL {right: .7em; left: auto}
.MathJax_MenuRadioCheck {position: absolute; left: 1em}
.MathJax_MenuRadioCheck.RTL {right: 1em; left: auto}
.MathJax_MenuLabel {padding: 2px 2em 4px 1.33em; font-style: italic}
.MathJax_MenuRule {border-top: 1px solid #CCCCCC; margin: 4px 1px 0px}
.MathJax_MenuDisabled {color: GrayText}
.MathJax_MenuActive {background-color: Highlight; color: HighlightText}
.MathJax_MenuDisabled:focus, .MathJax_MenuLabel:focus {background-color: #E8E8E8}
.MathJax_ContextMenu:focus {outline: none}
.MathJax_ContextMenu .MathJax_MenuItem:focus {outline: none}
#MathJax_AboutClose {top: .2em; right: .2em}
.MathJax_Menu .MathJax_MenuClose {top: -10px; left: -10px}
.MathJax_MenuClose {position: absolute; cursor: pointer; display: inline-block;
border: 2px solid #AAA; border-radius: 18px; -webkit-border-radius: 18px; -moz-
border-radius: 18px; -khtml-border-radius: 18px; font-family: 'Courier
New',Courier; font-size: 24px; color: #F0F0F0}
.MathJax_MenuClose span {display: block; background-color: #AAA; border: 1.5px
solid; border-radius: 18px; -webkit-border-radius: 18px; -moz-border-radius: 18px;
-khtml-border-radius: 18px; line-height: 0; padding: 8px 0 6px}
.MathJax_MenuClose:hover {color: white!important; border: 2px solid #CCC!important}
.MathJax_MenuClose:hover span {background-color: #CCC!important}
.MathJax_MenuClose:hover:focus {outline: none}
</style><style type="text/css">.MathJax_Preview .MJXf-math {color: inherit!
important}
</style><style type="text/css">.MJX_Assistive_MathML {position: absolute!important;
top: 0; left: 0; clip: rect(1px, 1px, 1px, 1px); padding: 1px 0 0 0!important;
border: 0!important; height: 1px!important; width: 1px!important; overflow: hidden!
important; display: block!important; -webkit-touch-callout: none; -webkit-user-
select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select:
none; user-select: none}
.MJX_Assistive_MathML.MJX_Assistive_MathML_Block {width: 100%!important}
</style><style type="text/css">#MathJax_Zoom {position: absolute; background-color:
#F0F0F0; overflow: auto; display: block; z-index: 301; padding: .5em; border: 1px
solid black; margin: 0; font-weight: normal; font-style: normal; text-align: left;
text-indent: 0; text-transform: none; line-height: normal; letter-spacing: normal;
word-spacing: normal; word-wrap: normal; white-space: nowrap; float: none; -webkit-
box-sizing: content-box; -moz-box-sizing: content-box; box-sizing: content-box;
box-shadow: 5px 5px 15px #AAAAAA; -webkit-box-shadow: 5px 5px 15px #AAAAAA; -moz-
box-shadow: 5px 5px 15px #AAAAAA; -khtml-box-shadow: 5px 5px 15px #AAAAAA; filter:
progid:[Link](OffX=2, OffY=2, Color='gray',
Positive='true')}
#MathJax_ZoomOverlay {position: absolute; left: 0; top: 0; z-index: 300; display:
inline-block; width: 100%; height: 100%; border: 0; padding: 0; margin: 0;
background-color: white; opacity: 0; filter: alpha(opacity=0)}
#MathJax_ZoomFrame {position: relative; display: inline-block; height: 0; width: 0}
#MathJax_ZoomEventTrap {position: absolute; left: 0; top: 0; z-index: 302; display:
inline-block; border: 0; padding: 0; margin: 0; background-color: white; opacity:
0; filter: alpha(opacity=0)}
</style><style type="text/css">.MathJax_Preview {color: #888; display: contents}
#MathJax_Message {position: fixed; left: 1em; bottom: 1.5em; background-color:
#E6E6E6; border: 1px solid #959595; margin: 0px; padding: 2px 8px; z-index: 102;
color: black; font-size: 80%; width: auto; white-space: nowrap}
#MathJax_MSIE_Frame {position: absolute; top: 0; left: 0; width: 0px; z-index: 101;
border: 0px; margin: 0px; padding: 0px}
.MathJax_Error {color: #CC0000; font-style: italic}
</style><style type="text/css">.MJXp-script {font-size: .8em}
.MJXp-right {-webkit-transform-origin: right; -moz-transform-origin: right; -ms-
transform-origin: right; -o-transform-origin: right; transform-origin: right}
.MJXp-bold {font-weight: bold}
.MJXp-italic {font-style: italic}
.MJXp-scr {font-family: MathJax_Script,'Times New Roman',Times,STIXGeneral,serif}
.MJXp-frak {font-family: MathJax_Fraktur,'Times New Roman',Times,STIXGeneral,serif}
.MJXp-sf {font-family: MathJax_SansSerif,'Times New Roman',Times,STIXGeneral,serif}
.MJXp-cal {font-family: MathJax_Caligraphic,'Times New
Roman',Times,STIXGeneral,serif}
.MJXp-mono {font-family: MathJax_Typewriter,'Times New
Roman',Times,STIXGeneral,serif}
.MJXp-largeop {font-size: 150%}
.[Link]-int {vertical-align: -.2em}
.MJXp-math {display: inline-block; line-height: 1.2; text-indent: 0; font-family:
'Times New Roman',Times,STIXGeneral,serif; white-space: nowrap; border-collapse:
collapse}
.MJXp-display {display: block; text-align: center; margin: 1em 0}
.MJXp-math span {display: inline-block}
.MJXp-box {display: block!important; text-align: center}
.MJXp-box:after {content: " "}
.MJXp-rule {display: block!important; margin-top: .1em}
.MJXp-char {display: block!important}
.MJXp-mo {margin: 0 .15em}
.MJXp-mfrac {margin: 0 .125em; vertical-align: .25em}
.MJXp-denom {display: inline-table!important; width: 100%}
.MJXp-denom > * {display: table-row!important}
.MJXp-surd {vertical-align: top}
.MJXp-surd > * {display: block!important}
.MJXp-script-box > * {display: table!important; height: 50%}
.MJXp-script-box > * > * {display: table-cell!important; vertical-align: top}
.MJXp-script-box > *:last-child > * {vertical-align: bottom}
.MJXp-script-box > * > * > * {display: block!important}
.MJXp-mphantom {visibility: hidden}
.MJXp-munderover, .MJXp-munder {display: inline-table!important}
.MJXp-over {display: inline-block!important; text-align: center}
.MJXp-over > * {display: block!important}
.MJXp-munderover > *, .MJXp-munder > * {display: table-row!important}
.MJXp-mtable {vertical-align: .25em; margin: 0 .125em}
.MJXp-mtable > * {display: inline-table!important; vertical-align: middle}
.MJXp-mtr {display: table-row!important}
.MJXp-mtd {display: table-cell!important; text-align: center; padding: .5em 0
0 .5em}
.MJXp-mtr > .MJXp-mtd:first-child {padding-left: 0}
.MJXp-mtr:first-child > .MJXp-mtd {padding-top: 0}
.MJXp-mlabeledtr {display: table-row!important}
.MJXp-mlabeledtr > .MJXp-mtd:first-child {padding-left: 0}
.MJXp-mlabeledtr:first-child > .MJXp-mtd {padding-top: 0}
.MJXp-merror {background-color: #FFFF88; color: #CC0000; border: 1px solid #CC0000;
padding: 1px 3px; font-style: normal; font-size: 90%}
.MJXp-scale0 {-webkit-transform: scaleX(.0); -moz-transform: scaleX(.0); -ms-
transform: scaleX(.0); -o-transform: scaleX(.0); transform: scaleX(.0)}
.MJXp-scale1 {-webkit-transform: scaleX(.1); -moz-transform: scaleX(.1); -ms-
transform: scaleX(.1); -o-transform: scaleX(.1); transform: scaleX(.1)}
.MJXp-scale2 {-webkit-transform: scaleX(.2); -moz-transform: scaleX(.2); -ms-
transform: scaleX(.2); -o-transform: scaleX(.2); transform: scaleX(.2)}
.MJXp-scale3 {-webkit-transform: scaleX(.3); -moz-transform: scaleX(.3); -ms-
transform: scaleX(.3); -o-transform: scaleX(.3); transform: scaleX(.3)}
.MJXp-scale4 {-webkit-transform: scaleX(.4); -moz-transform: scaleX(.4); -ms-
transform: scaleX(.4); -o-transform: scaleX(.4); transform: scaleX(.4)}
.MJXp-scale5 {-webkit-transform: scaleX(.5); -moz-transform: scaleX(.5); -ms-
transform: scaleX(.5); -o-transform: scaleX(.5); transform: scaleX(.5)}
.MJXp-scale6 {-webkit-transform: scaleX(.6); -moz-transform: scaleX(.6); -ms-
transform: scaleX(.6); -o-transform: scaleX(.6); transform: scaleX(.6)}
.MJXp-scale7 {-webkit-transform: scaleX(.7); -moz-transform: scaleX(.7); -ms-
transform: scaleX(.7); -o-transform: scaleX(.7); transform: scaleX(.7)}
.MJXp-scale8 {-webkit-transform: scaleX(.8); -moz-transform: scaleX(.8); -ms-
transform: scaleX(.8); -o-transform: scaleX(.8); transform: scaleX(.8)}
.MJXp-scale9 {-webkit-transform: scaleX(.9); -moz-transform: scaleX(.9); -ms-
transform: scaleX(.9); -o-transform: scaleX(.9); transform: scaleX(.9)}
.MathJax_PHTML .noError {vertical-align: ; font-size: 90%; text-align: left; color:
black; padding: 1px 3px; border: 1px solid}
</style><style type="text/css">.MathJax_Display {text-align: center; margin: 1em
0em; position: relative; display: block!important; text-indent: 0; max-width: none;
max-height: none; min-width: 0; min-height: 0; width: 100%}
.MathJax .merror {background-color: #FFFF88; color: #CC0000; border: 1px solid
#CC0000; padding: 1px 3px; font-style: normal; font-size: 90%}
.MathJax .MJX-monospace {font-family: monospace}
.MathJax .MJX-sans-serif {font-family: sans-serif}
#MathJax_Tooltip {background-color: InfoBackground; color: InfoText; border: 1px
solid black; box-shadow: 2px 2px 5px #AAAAAA; -webkit-box-shadow: 2px 2px 5px
#AAAAAA; -moz-box-shadow: 2px 2px 5px #AAAAAA; -khtml-box-shadow: 2px 2px 5px
#AAAAAA; filter: progid:[Link](OffX=2, OffY=2,
Color='gray', Positive='true'); padding: 3px 4px; z-index: 401; position: absolute;
left: 0; top: 0; width: auto; height: auto; display: none}
.MathJax {display: inline; font-style: normal; font-weight: normal; line-height:
normal; font-size: 100%; font-size-adjust: none; text-indent: 0; text-align: left;
text-transform: none; letter-spacing: normal; word-spacing: normal; word-wrap:
normal; white-space: nowrap; float: none; direction: ltr; max-width: none; max-
height: none; min-width: 0; min-height: 0; border: 0; padding: 0; margin: 0}
.MathJax:focus, body :focus .MathJax {display: inline-table}
.MathJax.MathJax_FullWidth {text-align: center; display: table-cell!important;
width: 10000em!important}
.MathJax img, .MathJax nobr, .MathJax a {border: 0; padding: 0; margin: 0; max-
width: none; max-height: none; min-width: 0; min-height: 0; vertical-align: 0;
line-height: normal; text-decoration: none}
img.MathJax_strut {border: 0!important; padding: 0!important; margin: 0!important;
vertical-align: 0!important}
.MathJax span {display: inline; position: static; border: 0; padding: 0; margin: 0;
vertical-align: 0; line-height: normal; text-decoration: none; box-sizing: content-
box}
.MathJax nobr {white-space: nowrap!important}
.MathJax img {display: inline!important; float: none!important}
.MathJax * {transition: none; -webkit-transition: none; -moz-transition: none; -ms-
transition: none; -o-transition: none}
.MathJax_Processing {visibility: hidden; position: fixed; width: 0; height: 0;
overflow: hidden}
.MathJax_Processed {display: none!important}
.MathJax_test {font-style: normal; font-weight: normal; font-size: 100%; font-size-
adjust: none; text-indent: 0; text-transform: none; letter-spacing: normal; word-
spacing: normal; overflow: hidden; height: 1px}
.MathJax_test.mjx-test-display {display: table!important}
.MathJax_test.mjx-test-inline {display: inline!important; margin-right: -1px}
.MathJax_test.mjx-test-default {display: block!important; clear: both}
.MathJax_ex_box {display: inline-block!important; position: absolute; overflow:
hidden; min-height: 0; max-height: none; padding: 0; border: 0; margin: 0; width:
1px; height: 60ex}
.MathJax_em_box {display: inline-block!important; position: absolute; overflow:
hidden; min-height: 0; max-height: none; padding: 0; border: 0; margin: 0; width:
1px; height: 60em}
.mjx-test-inline .MathJax_left_box {display: inline-block; width: 0; float: left}
.mjx-test-inline .MathJax_right_box {display: inline-block; width: 0; float: right}
.mjx-test-display .MathJax_right_box {display: table-cell!important; width:
10000em!important; min-width: 0; max-width: none; padding: 0; border: 0; margin: 0}
.MathJax .MathJax_HitBox {cursor: text; background: white; opacity: 0; filter:
alpha(opacity=0)}
.MathJax .MathJax_HitBox * {filter: none; opacity: 1; background: transparent}
#MathJax_Tooltip * {filter: none; opacity: 1; background: transparent}
@font-face {font-family: MathJax_Main; src:
url('[Link]
CSS/TeX/woff/MathJax_Main-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Main-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Main-bold; src:
url('[Link]
CSS/TeX/woff/MathJax_Main-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Main-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Main-italic; src:
url('[Link]
CSS/TeX/woff/MathJax_Main-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Main-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Math-italic; src:
url('[Link]
CSS/TeX/woff/MathJax_Math-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Math-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Caligraphic; src:
url('[Link]
CSS/TeX/woff/MathJax_Caligraphic-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Caligraphic-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Size1; src:
url('[Link]
CSS/TeX/woff/MathJax_Size1-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Size1-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Size2; src:
url('[Link]
CSS/TeX/woff/MathJax_Size2-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Size2-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Size3; src:
url('[Link]
CSS/TeX/woff/MathJax_Size3-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Size3-[Link]?V=2.7.9') format('opentype')}
@font-face {font-family: MathJax_Size4; src:
url('[Link]
CSS/TeX/woff/MathJax_Size4-[Link]?V=2.7.9') format('woff'),
url('[Link]
CSS/TeX/otf/MathJax_Size4-[Link]?V=2.7.9') format('opentype')}
.MathJax .noError {vertical-align: ; font-size: 90%; text-align: left; color:
black; padding: 1px 3px; border: 1px solid}
</style></head>
<body class=" "><div style="visibility: hidden; overflow: hidden; position:
absolute; top: 0px; height: 1px; width: auto; padding: 0px; border: 0px; margin:
0px; text-align: left; text-indent: 0px; text-transform: none; line-height: normal;
letter-spacing: normal; word-spacing: normal;"><div
id="MathJax_Hidden"></div></div><div id="MathJax_Message" style="display:
none;"></div><span style="display:none;" class="csrf-token" data-
csrf="f9d86a46f7d81154b506431c5e7ca8f2">&nbsp;</span>

<!-- .notificationTextCleaner used in [Link]() -->


<div class="notificationTextCleaner" style="font-size: 0"></div>
<div class="button-up" style="display: none; opacity: 0.7; width: 30px; height:
100%; position: fixed; left: 0px; top: 0px; cursor: pointer; text-align: center;
line-height: 30px; color: rgb(211, 219, 228); font-weight: bold; font-size:
20px;"><i class="icon-circle-arrow-up"></i></div>
<div class="verdictPrototypeDiv" style="display: none;"></div>

<!-- Codeforces JavaScripts. -->


<script type="text/javascript">
[Link] = function() {
var hash = 0, i, chr;
if ([Link] === 0) return hash;
for (i = 0; i < [Link]; i++) {
chr = [Link](i);
hash = ((hash << 5) - hash) + chr;
hash |= 0; // Convert to 32bit integer
}
return hash;
};

var queryMobile = [Link];


if (queryMobile === "true" || queryMobile === "false") {
[Link]("useMobile", queryMobile === "true");
} else {
var useMobile = [Link]("useMobile");
if (useMobile === true || useMobile === false) {
if (useMobile != false) {

[Link]([Link]([Link], "mobile",
useMobile));
}
}
}
</script>

<script type="text/javascript">
$(document).ready(function () {
(function () {
[Link][':'].containsCI = function(elem, index, match) {
return !match || ![Link] || [Link] < 4 || !match[3] || (
[Link] || [Link] || jQuery(elem).text() || ''
).toLowerCase().indexOf(match[3].toLowerCase()) >= 0;
}
}(jQuery));

$.ajaxPrefilter(function(options, originalOptions, xhr) {


var csrf = [Link]();

if (csrf) {
var data = [Link];
if ([Link] !== undefined) {
if ([Link]([Link]) ===
'[object String]') {
data = $.deparam([Link]);
}
} else {
data = {};
}
[Link] = $.param($.extend(data, { csrf_token: csrf }));
}
});

[Link] = function(callback) {
$.post("/data/time", {}, callback, "json");
}

[Link] = function () {
$("[Link] code").addClass("tt");
$("[Link] pre>code").addClass("prettyprint").removeClass("tt");
$("[Link] table").addClass("bordertable");
prettyPrint();
}

$.ajaxSetup({ scriptCharset: "utf-8" ,contentType: "application/x-www-form-


urlencoded; charset=UTF-8", headers: {
'X-Csrf-Token': [Link]()
}});

[Link]();

[Link]();

setTimeout(function() {
$(".second-level-menu-list").lavaLamp({
fx: "backout",
speed: 700
});
}, 100);

[Link]();
$("a[rel='photobox']").colorbox();

var count = 0;

function getDelay() {
var delay = 0;
var last = [Link]("LastOnlineTimeUpdaterMillis", 0);
if (last && last != null) {
var period = count < 20 ? 360 * 1000 : 600 * 1000;
delay = period - (new Date().getTime() - last);
if (delay < 0)
delay = 0;
}
return delay;
}

[Link](function () {
if (getDelay() <= 0 && count < 120) {
++count;
[Link]("/data/update-online");
}
}, 5000);

var handle = "g33431=user895";


$("[Link]-user:contains(" + handle + "), [Link]:contains(" +
handle + ")").each(function () {
if ($(this).text() == handle) {
var td = $(this).parent();
var tr = $(this).parent().parent();
if ([Link]("td") && [Link]("tr") && ![Link]("disable-highlight-
self")) {
info(handle);
[Link]("highlighted-row");
}
}
});

function showAnnouncements(json) {
//info("j=" + [Link](json));

if (json.t != "a") {
return;
}

setTimeout(function() {
[Link](json.d, "en");
}, [Link]() * 500);
}

function showEventCatcherUserMessage(json) {
if (json.t == "s") {
var points = json.d[5];
var passedTestCount = json.d[7];
var judgedTestCount = json.d[8];
var verdict = preparedVerdictFormats[json.d[12]];
var verdictPrototypeDiv = $(".verdictPrototypeDiv");
[Link](verdict);
if (judgedTestCount != null && judgedTestCount != undefined) {
[Link](".verdict-format-
judged").text(judgedTestCount);
}
if (passedTestCount != null && passedTestCount != undefined) {
[Link](".verdict-format-
passed").text(passedTestCount);
}
if (points != null && points != undefined) {
[Link](".verdict-format-points").text(points);
}
[Link]([Link]());
}
}

$(".clickable-title").each(function() {
var title = $(this).attr("data-title");
if (title) {
var tmp = [Link]("DIV");
[Link] = title;
$(this).attr("title", [Link] || [Link] || "");
}
});

$(".clickable-title").click(function() {
const title = $(this).attr("data-title");
const clazz = $(this).attr("data-clazz");
const props = {};
if (typeof (clazz) !== 'undefined') {
props['clazz'] = clazz;
}
if (title) {
[Link](title, null, null, props);
} else {
[Link]($(this).attr("title"), null, null, props);
}
}).css("position", "relative").css("bottom", "3px");

[Link]();

[Link]();

//[Link]();
if ([Link]) {
[Link] = new EventCatcher(
[Link],
[
[Link](),
[Link](),
[Link](),
[Link](),
[Link](),
[Link]()
]
);

if ([Link]()) {
[Link]([Link](),
function(json) {
showAnnouncements(json);
});
}

if ([Link]()) {
[Link]([Link](),
function(json) {
showAnnouncements(json);
});
}

if ([Link]()) {
[Link]([Link](),
function(json) {
showAnnouncements(json);
});
}

if ([Link]()) {
[Link]([Link](),
function(json) {
showAnnouncements(json);
});
}

if ([Link]()) {
[Link]([Link](),
function(json) {
showEventCatcherUserMessage(json);
});
}
}

[Link]("/group/jf2P3wolKK/data/contests");
[Link]();
[Link]("/data/problemTutorial");
});
</script>

<div id="body">
<script type="application/javascript">
[Link](function () {
var url = [Link];
var hashCode32 = [Link]([Link]()).toString();
var hashCode = "p" + hashCode32 + [Link]((hashCode32 +
url).hashCode());
var pvs = [Link]("pvs" + hashCode);
if (!pvs) {
$.post("/data/apv", {
ftaa: window._ftaa,
bfaa: window._bfaa,
url: url
}, function (json) {
if (json["success"] === "true") {
[Link]("pvs" + hashCode, true);
}
}, "json");
}
}, 5000);
</script>

<div id="header" style="position: relative;">


<div style="float:left; max-height: 60px;">
<a
href="[Link] height="65"
style="height: 65px;" alt="Codeforces" title="Codeforces" src="./Problem - B -
Codeforces.htxt_files/[Link]"></a>
</div>
<div class="lang-chooser">
<div style="text-align: right;">
<a
href="[Link]
580643/problem/B?locale=en"><img src="./Problem - B - Codeforces.htxt_files/[Link]"
title="In English" alt="In English"></a>
<a
href="[Link]
580643/problem/B?locale=ru"><img src="./Problem - B - Codeforces.htxt_files/[Link]"
title="По-русски" alt="По-русски"></a>
</div>

<div>
Bùi Hoàng Minh 2007
|
<a
href="[Link]
927f41/logout">Logout</a>

</div>

</div>
<br style="clear: both;">
</div>

<div class="roundbox menu-box borderTopRound borderBottomRound" style="">


<div class="menu-list-container">
<ul class="menu-list main-menu-list">
<li class=""><a
href="[Link]
contests">Contests</a></li>
</ul>
<br style="clear: both;">
</div>

</div>

<script type="text/javascript">
$(document).ready(function () {
$("[Link]").focus(function () {
if ($(this).attr("data-isPlaceholder") === "true") {
$(this).val("");
$(this).removeAttr("data-isPlaceholder");
}
});
});
</script>
<br style="height: 3em; clear: both;">

<div style="position: relative;">


<div id="sidebar">

<div class="roundbox sidebox borderTopRound " style="">


<table class="rtable ">
<tbody>
<tr>
<th class="left" style="width:100%;"><a style="color:
black"
href="[Link]
er HSG Fall 24</a></th>
</tr>
<tr>
<td class="left bottom" colspan="1"><span
class="contest-state-regular countdown" cdid="i1">Participant</span></td>
</tr>
</tbody>
</table>
</div>

<style data-nocturne="true" type="text/css">

</style>

<div class="roundbox sidebox GroupContestsSidebarFrame


_GroupContestsSidebarFrame_contests sidebar-menu borderTopRound " style="">
<div class="caption titled">→ Group Contests <i class="sidebar-
caption-icon las la-angle-down"></i>

<div class="top-links">
</div>
</div>
<ul style=" " data-page-url="/data/group/manage" data-extra-key-0="action"
data-extra-value-0="setGroupContestsSidebarFrameCollapsed" data-extra-key-
1="groupCode" data-extra-value-1="jf2P3wolKK">
<li class="active">
<a
href="[Link]
580643">
HSG_Fall_24: Đề 9 </a>
</li>
<li>
<a
href="[Link]
578173">
HSG Fall 24: Euler tour on tree </a>
</li>
<li>
<a
href="[Link]
575644">
HSG Fall 24: Segment tree </a>
</li>
<li>
<a
href="[Link]
568517">
HSG Fall 24: Contest 2 </a>
</li>
<li>
<a
href="[Link]
566866">
HSG Fall 24: Tree - Đồ thị cây </a>
</li>
<li>
<a
href="[Link]
563867">
HSG Fall 24: Hashing </a>
</li>
<li>
<a
href="[Link]
560118">
HSG Fall 24: Đường đi ngắn nhất - Dijkstra </a>
</li>
<li>
<a
href="[Link]
559364">
HSG Fall 24: Bai kiem tra 1 </a>
</li>
<li>
<a
href="[Link]
559277">
HSG Fall 24: Bonus DFS, BFS </a>
</li>
<li>
<a
href="[Link]
554314">
HSG_Fall24: Graph - đồ thị </a>
</li>
<li>
<a
href="[Link]
552262">
HSG Fall 24: Quy hoach dong </a>
</li>
<li>
<a
href="[Link]
550481">
HSG Fall 24: Binary search - Tim kiem nhi phan 2 </a>
</li>
<li>
<a
href="[Link]
550480">
HSG Fall 24: Binary search - Tim kiem nhi phan 1 </a>
</li>
<li>
<a
href="[Link]
548489">
HSG Fall 24: two pointers - hai con tro </a>
</li>
<li>
<a
href="[Link]
548487">
HSG Fall 24: Bitwise, bitmask, cac thao tac voi bit </a>
</li>
<li>
<a
href="[Link]
547142">
HSG_Fall24: Prefix sum - Tong cong don </a>
</li>
<li>
<a
href="[Link]
547119">
HSG_Fall24: Sorting - Sap xep </a>
</li>
<li>
<a
href="[Link]
545648">
HSG Fall 24: Số nguyên tố, sàng nguyên tố </a>
</li>
<li>
<a
href="[Link]
544145">
HSG Fall 24: Đệ quy, quay lui </a>
</li>
<li>
<a
href="[Link]
544097">
HSG Fall 24: STL - Vector, pair, set, map, priorty queue, stack, deque...
</a>
</li>
<li>
<a
href="[Link]
544090">
HSG Fall 24: Test </a>
</li>
</ul>
</div>

<script data-nocturne="true"> $(function () {


$(".GroupContestsSidebarFrame .sidebar-caption-icon").click(function() {
$(this).toggleClass("la-angle-down la-angle-right");
const $target = $(this).parent().next();
$[Link]();
const dataPageUrl = $[Link]("data-page-url");
const collapsed = $(this).hasClass("la-angle-right");
const params = {
action: "setCollapsed",
sidebarFrameSimpleClassName: "GroupContestsSidebarFrame",
collapsed
};
$.each($target[0].attributes, function(i, a) {
const name = [Link];
if ([Link]("data-extra-key-")) {
const key = [Link];
const keyIndex = parseInt([Link]("data-extra-
key-".length));
const value = $[Link]("data-extra-value-" + keyIndex);
params[key] = value;
}
});
$.post(dataPageUrl, params, function (result) {
if (result["success"] !== "true") {
[Link]("Failed to save collapsed state.");
}
}, "json");
return false;
});
}); </script>

<div class="roundbox sidebox borderTopRound " style="">


<table class="rtable ">
<tbody>
<tr>
<th class="left" style="width:100%;"><a style="color:
black" href="[Link]
contest/580643">HSG_Fall_24: Đề 9</a></th>
</tr>
<tr>
<td class="left " colspan="1"><span class="contest-
state-phase">Contest is running</span></td>
</tr>
<tr>
<td class="left dark" colspan="1"><span
class="contest-state-regular countdown before-contest-580643-finish" home="/static"
noredirection="true" textbeforeredirect="The coding phase of &quot;HSG_Fall_24: Đề
9&quot; is finished, reload the page to view changes"
cdid="i2">00:39:21</span></td>
</tr>
<tr>
<td class="left bottom" colspan="1"><span
class="contest-state-regular">Contestant</span></td>
</tr>
</tbody>
</table>
</div>

<style>
.[Link]-only select[name='programTypeId'],
.[Link]-only select[name='programTypeId'],
.[Link]-only .programSourceTr {
display: none !important;
}

.[Link]-only .programTypeNotice,
.[Link]-only .programTypeNotice {
display: none !important;
}

.outputOnlyProgramTypeIdNotice {
display: none;
font-size: 1.1rem !important;
}

.[Link]-only .outputOnlyProgramTypeIdNotice,
.[Link]-only .outputOnlyProgramTypeIdNotice {
display: block !important;
}
</style>

<style type="text/css">
.submitForm .field {
font-size: 1.1rem;
width: 3em !important;
padding-right: 1em;
}

.submitForm input, .submitForm select {


font-size: 1.1rem;
width: 17em;
}
</style>

<div class="roundbox sidebox borderTopRound " style="">


<div class="caption titled">→ Submit?
<div class="top-links">
</div>
</div>
<div>
<form method="post"
action="[Link]
contest/580643/problem/B?csrf_token=f9d86a46f7d81154b506431c5e7ca8f2"
enctype="multipart/form-data" class="submitForm"><input type="hidden"
name="csrf_token" value="f9d86a46f7d81154b506431c5e7ca8f2">
<input type="hidden" name="ftaa" value="">
<input type="hidden" name="bfaa" value="">
<input type="hidden" name="action"
value="submitSolutionFormSubmitted">
<input type="hidden" name="submittedProblemIndex"
value="B">
<input type="hidden" name="source" value="">

<table class="table-form no-autofocus" style="width:90%;">


<tbody><tr>
<td class="field">Language:</td>
<td>
<select name="programTypeId">
<option value="43">GNU GCC C11
5.1.0</option>
<option value="54"
selected="selected">GNU G++17 7.3.0</option>
<option value="89">GNU G++20 13.2 (64
bit, winlibs)</option>
<option value="91">GNU G++23 14.2 (64
bit, msys2)</option>
<option value="65">C# 8, .NET Core
3.1</option>
<option value="79">C# 10, .NET SDK
6.0</option>
<option value="9">C# Mono 6.8</option>
<option value="28">D DMD32
v2.105.0</option>
<option value="32">Go 1.22.2</option>
<option value="12">Haskell GHC
8.10.1</option>
<option value="87">Java 21
64bit</option>
<option value="36">Java 8
32bit</option>
<option value="83">Kotlin
1.7.20</option>
<option value="88">Kotlin
1.9.21</option>
<option value="19">OCaml
4.02.1</option>
<option value="3">Delphi 7</option>
<option value="4">Free Pascal
3.2.2</option>
<option value="51">[Link]
3.8.3</option>
<option value="13">Perl 5.20.1</option>
<option value="6">PHP 8.1.7</option>
<option value="7">Python
2.7.18</option>
<option value="31">Python
3.8.10</option>
<option value="40">PyPy 2.7.13
(7.3.0)</option>
<option value="41">PyPy 3.6.9
(7.3.0)</option>
<option value="70">PyPy 3.10 (7.3.15,
64bit)</option>
<option value="67">Ruby 3.2.2</option>
<option value="75">Rust 1.75.0
(2021)</option>
<option value="20">Scala
2.12.8</option>
<option value="34">JavaScript V8
4.8.0</option>
<option value="55">[Link] 15.8.0
(64bit)</option>
</select>
<div
class="outputOnlyProgramTypeIdNotice">ZIP</div>
</td>
</tr>
<tr style="padding: 0; margin: 0; height: 0.5rem;line-
height: 1rem;">
<td style="padding: 0; margin: 0; height:
0.5rem;"></td>
<td style="padding: 0; margin: 0; height: 0.5rem;">
<span class="programTypeNotice notice small"
style="position: relative; bottom:7px;"></span>
</td>
</tr>

<tr>
<td class="field">Choose file:</td>
<td>
<input name="sourceFile" type="file" value="">
</td>
</tr>

<tr>
<td colspan="2">
<div style="text-align: center;">

<div style="position: relative; display:


inline-block;">
<input style="width:10em;"
class="submit" type="submit" value="Submit" id="sidebarSubmitButton">
<script>
$(function() {
})
</script>
<img class="ajax-loading-gif"
style="display:none; position: absolute; right:-24px; bottom:0;" src="./Problem - B
- Codeforces.htxt_files/[Link]">
</div>
</div>
</td>
</tr>
</tbody></table>
<input type="hidden" name="_tta" value="726"></form>
</div>
</div>

<script type="text/javascript">
$(function() {
window._ftaa = "1mzow920b2wsbg4awi";
})
</script>

<script type="text/javascript">
$(function() {
window._bfaa = "4b1c73301711758aff71dee46fc03e72";
});
</script>

<script>
$(function () {
function adjustNotice(programTypeId) {
var $programTypeNotice = $(".programTypeNotice");
$[Link]("");
if (programTypeId === 7) {
$[Link]("Almost always, if you send a solution
on PyPy, it works much faster");
}
if (programTypeId === 31) {
$[Link]("Almost always, if you send a solution
on PyPy, it works much faster");
}
}

adjustNotice(54);

const $submittedProblemIndex = $
("select[name='submittedProblemIndex']");

function adjustSubmittedProblemIndex() {
const index = $[Link]();
const outputOnlyIndices = [];
const outputOnly = [Link](index) >= 0;
if (outputOnly) {
$[Link](".submit-
form").addClass("output-only");
} else {
$[Link](".submit-
form").removeClass("output-only");
}
}

$[Link](function () {
adjustSubmittedProblemIndex();
});

adjustSubmittedProblemIndex();

$("select[name='programTypeId']").change(function () {
adjustNotice(parseInt($(this).val()));
});

$(".submit-form, .submitForm").submitOnce(function () {
var form = $(this);
var $ftaa = [Link]("input[name='ftaa']");
var $bfaa = [Link]("input[name='bfaa']");

if (window._ftaa && window._bfaa) {


$[Link](window._ftaa);
$[Link](window._bfaa);
}

if ([Link]("enctype") === "multipart/form-data") {


var sourceFiles = [Link](".table-form
input[name=sourceFile]");

if ([Link] === 1 && sourceFiles[0].files &&


sourceFiles[0].[Link] === 0) {
[Link]("enctype");
}
}

return true;
});
});
</script>

<div class="roundbox sidebox borderTopRound " style="">


<div class="caption titled">→ Your points
<div class="top-links">
</div>
</div>
<table class="rtable smaller">
<tbody>
<tr>
<th class="left " style="width:2.5em;"></th>
<th class=" ">Points</th>
</tr>
<tr>
<td class="left dark "><b>A</b></td>
<td class=" dark ">100</td>
</tr>
<tr>
<td class="left "><b>B</b></td>
<td class=" "></td>
</tr>
<tr>
<td class="left dark "><b>C</b></td>
<td class=" dark "></td>
</tr>
<tr>
<td class="left bottom "><b>Total</b></td>
<td class="bottom "><b>100</b></td>
</tr>
</tbody>
</table>
</div>

<!-- ContestResourcesSidebarFrame: hidden. -->


</div>
<div id="pageContent" class="content-with-sidebar">
<div class="second-level-menu">
<ul class="second-level-menu-list"><li class="backLava" style="position: absolute;
display: block; margin: 0px; padding: 0px; left: 0px; top: 0px; width: 84px;
height: 20px; overflow: hidden;"><div class="leftLava"></div><div
class="bottomLava"></div><div class="cornerLava"></div></li>
<li class="current selectedLava"><a
href="[Link]
580643">Problems</a></li>
<li><a
href="[Link]
580643/submit">Submit Code</a></li>
<li><a
href="[Link]
580643/my">My Submissions</a></li>
<li><a
href="[Link]
580643/status">Status</a></li>
<li><a
href="[Link]
580643/standings/groupmates/true">Standings</a></li>
<li><a
href="[Link]
580643/customtest">Custom Invocation</a></li>
</ul>
</div>

<style>
#facebox .content:has(.diff-popup) {
width: 90vw;
max-width: 120rem !important;
}

.testCaseMarker {
position: absolute;
font-weight: bold;
font-size: 1rem;
}

.diff-popup {
width: 90vw;
max-width: 120rem !important;
display: none;
overflow: auto;
}

.input-output-copier {
font-size: 1.2rem;
float: right;
color: #888 !important;
cursor: pointer;
border: 1px solid rgb(185, 185, 185);
padding: 3px;
margin: 1px;
line-height: 1.1rem;
text-transform: none;
}

.input-output-copier:hover {
background-color: #def;
}

.test-explanation textarea {
width: 100%;
height: 1.5em;
}

.pending-submission-message {
color: darkorange !important;
}
</style>
<script>
const OPENING_SPACE = [Link](1001);
const CLOSING_SPACE = [Link](1002);

const nodeToText = function (node, pre) {


let result = [];

if ([Link] === "SCRIPT" || [Link] === "math"


|| ([Link] && [Link]("input-output-
copier")))
return [];

if ([Link] === "NOBR") {


[Link](OPENING_SPACE);
}

if ([Link] === Node.TEXT_NODE) {


let s = [Link];
if (!pre) {
s = [Link](/\s+/g, " ");
}
if ([Link] > 0) {
[Link](s);
}
}
if (pre && [Link] === "BR") {
[Link]("\n");
}

[Link](function (child) {
[Link](nodeToText(child, [Link] === "PRE").join(""));
});

if ([Link] === "DIV"


|| [Link] === "P"
|| [Link] === "PRE"
|| [Link] === "UL"
|| [Link] === "LI"
) {
[Link]("\n");
}

if ([Link] === "NOBR") {


[Link](CLOSING_SPACE);
}

return result;
}

const isSpecial = function (c) {


return c === ',' || c === '.' || c === ';' || c === ')' || c === ' ';
}

const convertStatementToText = function(statmentNode) {


const text = nodeToText(statmentNode, false).join("").replace(/ +/g, "
").replace(/\n\n+/g, "\n\n");
let result = [];
for (let i = 0; i < [Link]; i++) {
const c = [Link](i);
if (c === OPENING_SPACE) {
if (!((i > 0 && [Link](i - 1) === '(') || ([Link] >
0 && result[[Link] - 1] === ' '))) {
[Link]('+');
}
} else if (c === CLOSING_SPACE) {
if (!(i + 1 < [Link] && isSpecial([Link](i + 1)))) {
[Link]('-');
}
} else {
[Link](c);
}
}
return [Link]("").split("\n").map(value => [Link]()).join("\
n");
};
</script>
<div class="diff-popup">
</div>

<div class="problemindexholder" problemindex="B" data-


uuid="ps_76e1bebf0eacb39c63310f5e6b08da176e651183">
<div style="display: none; margin:1em 0;text-align: center; position:
relative;" class="alert alert-info diff-notifier">
<div>The problem statement has recently been changed. <a class="view-
changes"
href="[Link]
580643/problem/B#">View the changes.</a></div>
<span class="diff-notifier-close" style="position: absolute; top: 0.2em;
right: 0.3em; cursor: pointer; font-size: 1.4em;">×</span>
</div>
<div class="ttypography"><div class="problem-statement"><div
class="header"><div class="title"><span class="MathJax_Preview" style="color:
inherit;"></span><span class="MathJax" id="MathJax-Element-1-Frame" tabindex="0"
style="position: relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mn&gt;&lt;mi&gt;n&lt;/mi&gt;&lt;mo&gt;&amp;#x2212;&lt;/mo&gt;&lt;mi&gt;n&lt;/
mi&gt;&lt;mo&gt;=&lt;/mo&gt;&lt;mn&gt;2&lt;/mn&gt;&lt;mi&gt;n&lt;/mi&gt;&lt;/
math&gt;" role="presentation"><nobr aria-hidden="true"><span class="math"
id="MathJax-Span-1" style="width: 6.51em; display: inline-block;"><span
style="display: inline-block; position: relative; width: 5.399em; height: 0px;
font-size: 120%;"><span style="position: absolute; clip: rect(1.391em, 1005.36em,
2.383em, -999.998em); top: -2.181em; left: 0em;"><span class="mrow" id="MathJax-
Span-2"><span class="mn" id="MathJax-Span-3" style="font-family:
MathJax_Main;">3</span><span class="mi" id="MathJax-Span-4" style="font-family:
MathJax_Math-italic;">n</span><span class="mo" id="MathJax-Span-5" style="font-
family: MathJax_Main; padding-left: 0.24em;">−</span><span class="mi" id="MathJax-
Span-6" style="font-family: MathJax_Math-italic; padding-left:
0.24em;">n</span><span class="mo" id="MathJax-Span-7" style="font-family:
MathJax_Main; padding-left: 0.28em;">=</span><span class="mn" id="MathJax-Span-8"
style="font-family: MathJax_Main; padding-left: 0.28em;">2</span><span class="mi"
id="MathJax-Span-9" style="font-family: MathJax_Math-italic;">n</span></span><span
style="display: inline-block; width: 0px; height:
2.185em;"></span></span></span><span style="display: inline-block; overflow:
hidden; vertical-align: -0.14em; border-left: 0px solid; width: 0px; height:
1.002em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
mi><mo>=</mo><mn>2</mn><mi>n</mi></math></span></span><script type="math/tex"
id="MathJax-Element-1">3n - n = 2n</script></div><div class="time-limit"><div
class="property-title">time limit per test</div>1 second</div><div class="memory-
limit"><div class="property-title">memory limit per test</div>256
megabytes</div><div class="input-file input-standard"><div class="property-
title">input</div>standard input</div><div class="output-file output-standard"><div
class="property-title">output</div>standard output</div></div><div><p>Cho dãy số
<span class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-2-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-10" style="width: 0.658em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.539em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.61em,
1000.54em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-11"><span class="mi" id="MathJax-Span-12" style="font-family:
MathJax_Math-italic;">a</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 0.718em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-2">a</script> gồm <span class="MathJax_Preview"
style="color: inherit;"></span><span class="MathJax" id="MathJax-Element-3-Frame"
tabindex="0" style="position: relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mn&gt;&lt;mi&gt;n&lt;/mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-
hidden="true"><span class="math" id="MathJax-Span-13" style="width: 1.313em;
display: inline-block;"><span style="display: inline-block; position: relative;
width: 1.074em; height: 0px; font-size: 120%;"><span style="position: absolute;
clip: rect(1.372em, 1001.07em, 2.384em, -999.997em); top: -2.199em; left:
0em;"><span class="mrow" id="MathJax-Span-14"><span class="mn" id="MathJax-Span-15"
style="font-family: MathJax_Main;">3</span><span class="mi" id="MathJax-Span-16"
style="font-family: MathJax_Math-italic;">n</span></span><span style="display:
inline-block; width: 0px; height: 2.205em;"></span></span></span><span
style="display: inline-block; overflow: hidden; vertical-align: -0.068em; border-
left: 0px solid; width: 0px; height: 1.004em;"></span></span></nobr><span
class="MJX_Assistive_MathML" role="presentation"><math
xmlns="[Link]
span><script type="math/tex" id="MathJax-Element-3">3n</script> phần tử. Hãy xóa
<span class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-4-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-17" style="width: 0.717em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.598em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.61em,
1000.6em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-18"><span class="mi" id="MathJax-Span-19" style="font-family:
MathJax_Math-italic;">n</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 0.718em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-4">n</script> phần tử khỏi <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-5-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-20" style="width: 0.658em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.539em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.61em,
1000.54em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-21"><span class="mi" id="MathJax-Span-22" style="font-family:
MathJax_Math-italic;">a</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 0.718em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-5">a</script> để tạo thành một dãy <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-6-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-23" style="width: 0.539em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.42em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.313em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-24"><span class="mi" id="MathJax-Span-25" style="font-family:
MathJax_Math-italic;">b</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-6">b</script> sao cho điểm số của dãy <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-7-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-26" style="width: 0.539em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.42em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.313em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-27"><span class="mi" id="MathJax-Span-28" style="font-family:
MathJax_Math-italic;">b</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-7">b</script> là lớn nhất có thể.</p><p>Điểm số
dãy <span class="MathJax_Preview" style="color: inherit;"></span><span
class="MathJax" id="MathJax-Element-8-Frame" tabindex="0" style="position:
relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-29" style="width: 0.539em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.42em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.313em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-30"><span class="mi" id="MathJax-Span-31" style="font-family:
MathJax_Math-italic;">b</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-8">b</script> bằng tổng <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-9-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-32" style="width: 0.717em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.598em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.61em,
1000.6em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-33"><span class="mi" id="MathJax-Span-34" style="font-family:
MathJax_Math-italic;">n</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 0.718em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-9">n</script> phần tử đầu tiên của dãy <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-10-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-35" style="width: 0.539em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.42em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.313em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-36"><span class="mi" id="MathJax-Span-37" style="font-family:
MathJax_Math-italic;">b</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-10">b</script> trừ đi tổng <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-11-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-38" style="width: 0.539em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.42em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.313em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-39"><span class="mi" id="MathJax-Span-40" style="font-family:
MathJax_Math-italic;">b</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-11">b</script> phần tử cuối cùng của dãy <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-12-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-41" style="width: 0.539em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.42em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.313em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-42"><span class="mi" id="MathJax-Span-43" style="font-family:
MathJax_Math-italic;">b</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-12">b</script>.</p></div><div class="input-
specification"><div class="section-title">Input</div><p>Dòng đầu tiên gồm số <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-13-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-44" style="width: 0.717em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.598em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.61em,
1000.6em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-45"><span class="mi" id="MathJax-Span-46" style="font-family:
MathJax_Math-italic;">n</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 0.718em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-13">n</script> - (<span class="MathJax_Preview"
style="color: inherit;"></span><span class="MathJax" id="MathJax-Element-14-Frame"
tabindex="0" style="position: relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mn&gt;&lt;mo&gt;&amp;#x2264;&lt;/mo&gt;&lt;mi&gt;n&lt;/
mi&gt;&lt;mo&gt;&amp;#x2264;&lt;/mo&gt;&lt;msup&gt;&lt;mn&gt;10&lt;/
mn&gt;&lt;mn&gt;5&lt;/mn&gt;&lt;/msup&gt;&lt;/math&gt;" role="presentation"><nobr
aria-hidden="true"><span class="math" id="MathJax-Span-47" style="width: 6.372em;
display: inline-block;"><span style="display: inline-block; position: relative;
width: 5.301em; height: 0px; font-size: 120%;"><span style="position: absolute;
clip: rect(1.134em, 1005.3em, 2.503em, -999.997em); top: -2.199em; left:
0em;"><span class="mrow" id="MathJax-Span-48"><span class="mn" id="MathJax-Span-49"
style="font-family: MathJax_Main;">1</span><span class="mo" id="MathJax-Span-50"
style="font-family: MathJax_Main; padding-left: 0.301em;">≤</span><span class="mi"
id="MathJax-Span-51" style="font-family: MathJax_Math-italic; padding-left:
0.301em;">n</span><span class="mo" id="MathJax-Span-52" style="font-family:
MathJax_Main; padding-left: 0.301em;">≤</span><span class="msubsup" id="MathJax-
Span-53" style="padding-left: 0.301em;"><span style="display: inline-block;
position: relative; width: 1.432em; height: 0px;"><span style="position: absolute;
clip: rect(3.158em, 1000.96em, 4.17em, -999.997em); top: -3.985em; left:
0em;"><span class="mn" id="MathJax-Span-54" style="font-family:
MathJax_Main;">10</span><span style="display: inline-block; width: 0px; height:
3.991em;"></span></span><span style="position: absolute; top: -4.402em; left:
1.015em;"><span class="mn" id="MathJax-Span-55" style="font-size: 70.7%; font-
family: MathJax_Main;">5</span><span style="display: inline-block; width: 0px;
height: 3.991em;"></span></span></span></span></span><span style="display: inline-
block; width: 0px; height: 2.205em;"></span></span></span><span style="display:
inline-block; overflow: hidden; vertical-align: -0.211em; border-left: 0px solid;
width: 0px; height: 1.361em;"></span></span></nobr><span
class="MJX_Assistive_MathML" role="presentation"><math
xmlns="[Link]
mo><msup><mn>10</mn><mn>5</mn></msup></math></span></span><script type="math/tex"
id="MathJax-Element-14">1 \le n \le 10^5</script>)</p><p>Dòng thứ hai gồm <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-15-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
mn&gt;&lt;mi&gt;n&lt;/mi&gt;&lt;/math&gt;"
role="presentation"><nobr aria-hidden="true"><span class="math" id="MathJax-Span-
56" style="width: 1.313em; display: inline-block;"><span style="display: inline-
block; position: relative; width: 1.074em; height: 0px; font-size: 120%;"><span
style="position: absolute; clip: rect(1.372em, 1001.07em, 2.384em, -999.997em);
top: -2.199em; left: 0em;"><span class="mrow" id="MathJax-Span-57"><span class="mn"
id="MathJax-Span-58" style="font-family: MathJax_Main;">3</span><span class="mi"
id="MathJax-Span-59" style="font-family: MathJax_Math-italic;">n</span></span><span
style="display: inline-block; width: 0px; height:
2.205em;"></span></span></span><span style="display: inline-block; overflow:
hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px; height:
1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
span><script type="math/tex" id="MathJax-Element-15">3n</script> số nguyên <span
class="MathJax_Preview" style="color: inherit;"></span><span class="MathJax"
id="MathJax-Element-16-Frame" tabindex="0" style="position: relative;" data-
mathml="&lt;math
xmlns=&quot;[Link]
/mi&gt;&lt;mn&gt;1&lt;/mn&gt;&lt;/msub&gt;&lt;mo&gt;,&lt;/
mo&gt;&lt;msub&gt;&lt;mi&gt;a&lt;/mi&gt;&lt;mn&gt;2&lt;/mn&gt;&lt;/
msub&gt;&lt;mo&gt;,&lt;/mo&gt;&lt;mo&gt;.&lt;/mo&gt;&lt;mo&gt;.&lt;/
mo&gt;&lt;mo&gt;.&lt;/mo&gt;&lt;mo&gt;,&lt;/mo&gt;&lt;msub&gt;&lt;mi&gt;a&lt;/
mi&gt;&lt;mrow
class=&quot;MJX-TeXAtom-ORD&quot;&gt;&lt;mn&gt;3&lt;/mn&gt;&lt;mi&gt;n&lt;/
mi&gt;&lt;/mrow&gt;&lt;/msub&gt;&lt;/math&gt;" role="presentation"><nobr aria-
hidden="true"><span class="math" id="MathJax-Span-60" style="width: 7.265em;
display: inline-block;"><span style="display: inline-block; position: relative;
width: 6.015em; height: 0px; font-size: 120%;"><span style="position: absolute;
clip: rect(1.61em, 1006.01em, 2.562em, -999.997em); top: -2.199em; left:
0em;"><span class="mrow" id="MathJax-Span-61"><span class="msubsup" id="MathJax-
Span-62"><span style="display: inline-block; position: relative; width: 0.955em;
height: 0px;"><span style="position: absolute; clip: rect(3.396em, 1000.54em,
4.17em, -999.997em); top: -3.985em; left: 0em;"><span class="mi" id="MathJax-Span-
63" style="font-family: MathJax_Math-italic;">a</span><span style="display: inline-
block; width: 0px; height: 3.991em;"></span></span><span style="position: absolute;
top: -3.807em; left: 0.539em;"><span class="mn" id="MathJax-Span-64" style="font-
size: 70.7%; font-family: MathJax_Main;">1</span><span style="display: inline-
block; width: 0px; height: 3.991em;"></span></span></span></span><span class="mo"
id="MathJax-Span-65" style="font-family: MathJax_Main;">,</span><span
class="msubsup" id="MathJax-Span-66" style="padding-left: 0.182em;"><span
style="display: inline-block; position: relative; width: 0.955em; height:
0px;"><span style="position: absolute; clip: rect(3.396em, 1000.54em, 4.17em, -
999.997em); top: -3.985em; left: 0em;"><span class="mi" id="MathJax-Span-67"
style="font-family: MathJax_Math-italic;">a</span><span style="display: inline-
block; width: 0px; height: 3.991em;"></span></span><span style="position: absolute;
top: -3.807em; left: 0.539em;"><span class="mn" id="MathJax-Span-68" style="font-
size: 70.7%; font-family: MathJax_Main;">2</span><span style="display: inline-
block; width: 0px; height: 3.991em;"></span></span></span></span><span class="mo"
id="MathJax-Span-69" style="font-family: MathJax_Main;">,</span><span class="mo"
id="MathJax-Span-70" style="font-family: MathJax_Main; padding-left:
0.182em;">.</span><span class="mo" id="MathJax-Span-71" style="font-family:
MathJax_Main; padding-left: 0.182em;">.</span><span class="mo" id="MathJax-Span-72"
style="font-family: MathJax_Main; padding-left: 0.182em;">.</span><span class="mo"
id="MathJax-Span-73" style="font-family: MathJax_Main; padding-left:
0.182em;">,</span><span class="msubsup" id="MathJax-Span-74" style="padding-left:
0.182em;"><span style="display: inline-block; position: relative; width: 1.372em;
height: 0px;"><span style="position: absolute; clip: rect(3.396em, 1000.54em,
4.17em, -999.997em); top: -3.985em; left: 0em;"><span class="mi" id="MathJax-Span-
75" style="font-family: MathJax_Math-italic;">a</span><span style="display: inline-
block; width: 0px; height: 3.991em;"></span></span><span style="position: absolute;
top: -3.807em; left: 0.539em;"><span class="texatom" id="MathJax-Span-76"><span
class="mrow" id="MathJax-Span-77"><span class="mn" id="MathJax-Span-78"
style="font-size: 70.7%; font-family: MathJax_Main;">3</span><span class="mi"
id="MathJax-Span-79" style="font-size: 70.7%; font-family: MathJax_Math-
italic;">n</span></span></span><span style="display: inline-block; width: 0px;
height: 3.991em;"></span></span></span></span></span><span style="display: inline-
block; width: 0px; height: 2.205em;"></span></span></span><span style="display:
inline-block; overflow: hidden; vertical-align: -0.282em; border-left: 0px solid;
width: 0px; height: 0.932em;"></span></span></nobr><span
class="MJX_Assistive_MathML" role="presentation"><math
xmlns="[Link]
msub><mo>,</mo><msub><mi>a</mi><mn>2</mn></msub><mo>,</mo><mo>.</mo><mo>.</
mo><mo>.</mo><mo>,</mo><msub><mi>a</mi><mrow
class="MJX-TeXAtom-ORD"><mn>3</mn><mi>n</mi></mrow></msub></math></span></
span><script type="math/tex" id="MathJax-Element-16">a_1, a_2, ... ,
a_{3n}</script> (<span class="MathJax_Preview" style="color: inherit;"></span><span
class="MathJax" id="MathJax-Element-17-Frame" tabindex="0" style="position:
relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mn&gt;&lt;mo&gt;&amp;#x2264;&lt;/mo&gt;&lt;msub&gt;&lt;mi&gt;a&lt;/
mi&gt;&lt;mi&gt;i&lt;/mi&gt;&lt;/msub&gt;&lt;mo&gt;&amp;#x2264;&lt;/
mo&gt;&lt;msup&gt;&lt;mn&gt;10&lt;/mn&gt;&lt;mn&gt;9&lt;/mn&gt;&lt;/msup&gt;&lt;/
math&gt;" role="presentation"><nobr aria-hidden="true"><span class="math"
id="MathJax-Span-80" style="width: 6.67em; display: inline-block;"><span
style="display: inline-block; position: relative; width: 5.539em; height: 0px;
font-size: 120%;"><span style="position: absolute; clip: rect(1.134em, 1005.54em,
2.562em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow" id="MathJax-
Span-81"><span class="mn" id="MathJax-Span-82" style="font-family:
MathJax_Main;">1</span><span class="mo" id="MathJax-Span-83" style="font-family:
MathJax_Main; padding-left: 0.301em;">≤</span><span class="msubsup" id="MathJax-
Span-84" style="padding-left: 0.301em;"><span style="display: inline-block;
position: relative; width: 0.836em; height: 0px;"><span style="position: absolute;
clip: rect(3.396em, 1000.54em, 4.17em, -999.997em); top: -3.985em; left:
0em;"><span class="mi" id="MathJax-Span-85" style="font-family: MathJax_Math-
italic;">a</span><span style="display: inline-block; width: 0px; height:
3.991em;"></span></span><span style="position: absolute; top: -3.807em; left:
0.539em;"><span class="mi" id="MathJax-Span-86" style="font-size: 70.7%; font-
family: MathJax_Math-italic;">i</span><span style="display: inline-block; width:
0px; height: 3.991em;"></span></span></span></span><span class="mo" id="MathJax-
Span-87" style="font-family: MathJax_Main; padding-left: 0.301em;">≤</span><span
class="msubsup" id="MathJax-Span-88" style="padding-left: 0.301em;"><span
style="display: inline-block; position: relative; width: 1.432em; height:
0px;"><span style="position: absolute; clip: rect(3.158em, 1000.96em, 4.17em, -
999.997em); top: -3.985em; left: 0em;"><span class="mn" id="MathJax-Span-89"
style="font-family: MathJax_Main;">10</span><span style="display: inline-block;
width: 0px; height: 3.991em;"></span></span><span style="position: absolute; top: -
4.402em; left: 1.015em;"><span class="mn" id="MathJax-Span-90" style="font-size:
70.7%; font-family: MathJax_Main;">9</span><span style="display: inline-block;
width: 0px; height: 3.991em;"></span></span></span></span></span><span
style="display: inline-block; width: 0px; height:
2.205em;"></span></span></span><span style="display: inline-block; overflow:
hidden; vertical-align: -0.282em; border-left: 0px solid; width: 0px; height:
1.361em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
mi><mi>i</mi></msub><mo>≤</mo><msup><mn>10</mn><mn>9</mn></msup></math></span></
span><script type="math/tex" id="MathJax-Element-17">1 \le a_i \le 10^9</script>)
mô tả dãy <span class="MathJax_Preview" style="color: inherit;"></span><span
class="MathJax" id="MathJax-Element-18-Frame" tabindex="0" style="position:
relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-91" style="width: 0.658em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.539em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.61em,
1000.54em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-92"><span class="mi" id="MathJax-Span-93" style="font-family:
MathJax_Math-italic;">a</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 0.718em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-18">a</script>.</p></div><div class="output-
specification"><div
class="section-title">Output</div><p>In ra <span class="MathJax_Preview"
style="color: inherit;"></span><span class="MathJax" id="MathJax-Element-19-Frame"
tabindex="0" style="position: relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mn&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-94" style="width: 0.598em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.479em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.372em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-95"><span class="mn" id="MathJax-Span-96" style="font-family:
MathJax_Main;">1</span></span><span style="display: inline-block; width: 0px;
height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 0.932em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-19">1</script> số nguyên là số điểm tối đa của
dãy <span class="MathJax_Preview" style="color: inherit;"></span><span
class="MathJax" id="MathJax-Element-20-Frame" tabindex="0" style="position:
relative;" data-mathml="&lt;math
xmlns=&quot;[Link]
mi&gt;&lt;/math&gt;" role="presentation"><nobr aria-hidden="true"><span
class="math" id="MathJax-Span-97" style="width: 0.539em; display: inline-
block;"><span style="display: inline-block; position: relative; width: 0.42em;
height: 0px; font-size: 120%;"><span style="position: absolute; clip: rect(1.313em,
1000.42em, 2.384em, -999.997em); top: -2.199em; left: 0em;"><span class="mrow"
id="MathJax-Span-98"><span class="mi" id="MathJax-Span-99" style="font-family:
MathJax_Math-italic;">b</span></span><span style="display: inline-block; width:
0px; height: 2.205em;"></span></span></span><span style="display: inline-block;
overflow: hidden; vertical-align: -0.068em; border-left: 0px solid; width: 0px;
height: 1.004em;"></span></span></nobr><span class="MJX_Assistive_MathML"
role="presentation"><math
xmlns="[Link]
type="math/tex" id="MathJax-Element-20">b</script> có thể tạo.</p></div><div
class="sample-tests"><div class="section-title">Examples</div><div class="sample-
test"><div class="input"><div class="title">Input<div title="Copy" data-clipboard-
target="#id006772145408221346" id="id008410523724097063" class="input-output-
copier">Copy</div></div><pre id="id006772145408221346">1
5 10 2
</pre></div><div class="output"><div class="title">Output<div title="Copy" data-
clipboard-target="#id00212689316075116" id="id007993338320460381" class="input-
output-copier">Copy</div></div><pre id="id00212689316075116">8</pre></div><div
class="input"><div class="title">Input<div title="Copy" data-clipboard-
target="#id009776316883899596" id="id0020019531513239808" class="input-output-
copier">Copy</div></div><pre id="id009776316883899596">2
8 3 5 7 6 2
</pre></div><div class="output"><div class="title">Output<div title="Copy" data-
clipboard-target="#id004707450501242212" id="id0043085934480466537" class="input-
output-copier">Copy</div></div><pre
id="id004707450501242212">7</pre></div></div></div></div><p> </p></div>
</div>
<script type="text/javascript">
$(document).ready(function () {
[Link] = new Set();

function endsWith(string, suffix) {


return [Link](suffix, [Link] - [Link]) !== -1;
}

const inputFileDiv = $("[Link]-file");


const inputFile = [Link]();
const outputFileDiv = $("[Link]-file");
const outputFile = [Link]();

if (!endsWith(inputFile, "standard input")


&& !endsWith(inputFile, "standard input")) {
[Link]("style", "font-weight: bold");
}

if (!endsWith(outputFile, "standard output")


&& !endsWith(outputFile, "standard output")) {
[Link]("style", "font-weight: bold");
}

const titleDiv = $("[Link] [Link]");

[Link] = function (search, replace) {


return [Link](search).join(replace);
};

$(".sample-test .title").each(function () {
const preId = ("id" + [Link]()).replaceAll(".", "0");
const cpyId = ("id" + [Link]()).replaceAll(".", "0");

$(this).parent().find("pre").attr("id", preId);
const $copy = $("<div title='Copy' data-clipboard-target='#" + preId +
"' id='" + cpyId + "' class='input-output-copier'>Copy</div>");
$(this).append($copy);

const clipboard = new Clipboard('#' + cpyId, {


text: function (trigger) {
const pre = [Link]('#' + preId);
const lines = [Link](".test-example-line");
return [Link]([Link],
[Link]);
}
});

const isInput = $(this).parent().hasClass("input");

[Link]('success', function (e) {


if (isInput) {
[Link]("The example input has been copied into
the clipboard");
} else {
[Link]("The example output has been copied into
the clipboard");
}
[Link]();
});
});

$(".test-form-item input").change(function () {
addPendingSubmissionMessage($($(this).closest("form")), "You changed
the answer, do not forget to submit it if you want to save the changes");
const index = $
(this).closest(".problemindexholder").attr("problemindex");
let test = "";
$(this).closest("form input").each(function () {
const test_ = $(this).attr("name");
if (test_ && test_.substring(0, 4) === "test") {
test = test_;
}
});
if ([Link] > 0 && [Link] > 0) {
const indexTest = index + "::" + test;
[Link](indexTest);
}
});

$(window).on('beforeunload', function () {
if ([Link] > 0) {
return 'Dialog text here';
}
});

autosize($('.test-explanation textarea'));

$(".test-example-line").hover(function() {
$(this).attr("class").split(" ").forEach((clazz) => {
if ([Link](0, "test-example-line-".length) === "test-example-
line-") {
let end = [Link]("test-example-line-".length);
if (end !== "even" && end !== "odd" && end !== "0") {
let top = 1E20;
let left = 1E20;
let problem = $(this).closest(".problemindexholder");
$(this).closest(".input").find("." +
clazz).css("background-color", "#FFFDE7").each(function() {
top = [Link](top, $(this).offset().top);
left = [Link](left, $(this).offset().left);
});
let testCaseMarker = [Link](".testCaseMarker_" +
end);
if ([Link] === 0) {
const html = "<div class=\"testCaseMarker
testCaseMarker_" + end + " notice\"></div>";
[Link]($(html));
testCaseMarker = [Link](".testCaseMarker_" +
end);
}
if (testCaseMarker) {
[Link]()
.offset({top, left: left - 20})
.text(end);
}
}
}
});
}, function() {
$(this).attr("class").split(" ").forEach((clazz) => {
if ([Link](0, "test-example-line-".length) === "test-example-
line-") {
let end = [Link]("test-example-line-".length);
if (end !== "even" && end !== "odd" && end !== "0") {
$("." + clazz).css("background-color", "");
$
(this).closest(".problemindexholder").find(".testCaseMarker_" + end).hide();
}
}
});
});

});
</script>

</div>
</div>
<br style="clear: both;">
<div id="footer">
<div>Codeforces (c) Copyright 2010-2025 Mike Mirzayanov</div>
<div>The only programming contests Web 2.0 platform</div>
<div>Server time: Jan/13/2025 21:13:24<sup title="timezone
offset" style="font-size:8px;">UTC+7</sup> (i1).</div>
<div>Desktop version, switch to <a rel="nofollow"
class="switchToMobile"
href="[Link]
580643/problem/B?mobile=true">mobile version</a>.</div>
<div class="smaller"><a
href="[Link]
Policy</a></div>

<div style="margin-top: 25px;">


Powered by
</div>
<div style="margin-top: 8px; padding-bottom: 20px;">
<img style="margin-right: 1em; width: 150px;"
src="./Problem - B - Codeforces.htxt_files/[Link]"
alt="Codeforces" title="Codeforces">
</div>
</div>
<script type="text/javascript">
$(function() {
$(".switchToMobile").click(function() {

[Link]([Link]([Link], "mobile",
"true"));
return false;
});
$(".switchToDesktop").click(function() {

[Link]([Link]([Link], "mobile",
"false"));
return false;
});
});
</script>
<script type="text/javascript">
$(document).ready(function () {
if ($(window).width() < 1600) {
$('.button-up').css('width', '30px').css('line-height',
'30px').css('font-size', '20px');
}

if ($(window).width() >= 1200) {


$ (window).scroll (function () {
if ($ (this).scrollTop () > 100) {
$ ('.button-up').fadeIn();
} else {
$ ('.button-up').fadeOut();
}
});

$('.button-up').click(function () {
$('body,html').animate({
scrollTop: 0
}, 500);
return false;
});

$('.button-up').hover(function () {
$(this).animate({
'opacity':'1'
}).css({'background-color':'#e7ebf0','color':'#6a86a4'});
}, function () {
$(this).animate({
'opacity':'0.7'
}).css({'background':'none','color':'#d3dbe4'});;
});
}
[Link]();
});
</script>
<div class="userListsFacebox" style="display:none;">
<div style="padding: 0.5em; width: 600px; max-height: 200px; overflow-y:
auto">
<div class="datatable" style="background-color: #E1E1E1; padding-bottom: 3px;">
<div class="lt">&nbsp;</div>
<div class="rt">&nbsp;</div>
<div class="lb">&nbsp;</div>
<div class="rb">&nbsp;</div>

<div style="padding: 4px 0 0 6px;font-size:1.4rem;position:relative;">


User lists

<div style="position:absolute;right:0.25em;top:0.35em;">
<span style="padding:0;position:relative;bottom:2px;"
class="rowCount"></span>

<img class="closed" src="./Problem - B -


Codeforces.htxt_files/[Link]">

<span class="filter" style="display:none;">


<img class="opened" src="./Problem - B -
Codeforces.htxt_files/[Link]">
<input style="padding:0 0 0
20px;position:relative;bottom:2px;border:1px solid #aaa;height:17px;font-
size:1.3rem;">
</span>
</div>
</div>
<div style="background-color: white;margin:0.3em 3px 0
3px;position:relative;">
<div class="ilt">&nbsp;</div>
<div class="irt">&nbsp;</div>
<table class="">
<thead>
<tr>
<th class="top left right">Name</th>
</tr>
</thead>
<tbody>
<tr class="no-items visible"><td style="text-align:left;"
colspan="32" class="bottom dark left right">No items</td></tr></tbody>
</table>
</div>
</div>
<script type="text/javascript">
$(document).ready(function () {
// Create new ':containsIgnoreCase' selector for search
[Link][':'].containsIgnoreCase = function(a, i, m) {
return jQuery(a).text().toUpperCase()
.indexOf(m[3].toUpperCase()) >= 0;
};

if ([Link] == undefined) {
[Link] = function(i) {
var parent = $(i).parent().parent().parent().parent();
$("[Link]-items", parent).remove();
$("tr", parent).hide().removeClass('visible');
var text = $(i).val();
if (text) {
$("tr" + ":containsIgnoreCase('" + text + "')",
parent).show().addClass('visible');
} else {
[Link](".rowCount").text("");
$("tr", parent).show().addClass('visible');
}

var found = false;


var visibleRowCount = 0;
$("tr", parent).each(function () {
if (!found) {
if ($(this).find("th").size() > 0) {
$(this).show().addClass('visible');
found = true;
}
}
if ($(this).hasClass('visible')) {
visibleRowCount++;
}
});
if (text) {
[Link](".rowCount").text("Matches: " +
(visibleRowCount - (found ? 1 : 0)));
}
if (visibleRowCount == (found ? 1 : 0)) {
$("<tr class='no-items visible'><td style=\"text-
align:left;\"colspan=\"32\">No items<\/td><\/tr>").appendTo($
(parent).find('table'));
}
$(parent).find("tr td").removeClass("dark");
$(parent).find("[Link]:odd td").addClass("dark");
}

$(".datatable .closed").click(function () {
var parent = $(this).parent();
$(this).hide();
$(".filter", parent).fadeIn(function () {
$("input", parent).val("").focus().css("border", "1px
solid #aaa");
});
});

$(".datatable .opened").click(function () {
var parent = $(this).parent().parent();
$(".filter", parent).fadeOut(function () {
$(".closed", parent).show();
$("input", parent).val("").each(function () {
[Link](this);
});
});
});

$(".datatable .filter input").keyup(function(e) {


[Link](this);
[Link]();
[Link]();
});

$(".datatable table").each(function () {
var found = false;
$("tr", this).each(function () {
if (!found && $(this).find("th").size() == 0) {
found = true;
}
});
if (!found) {
$("<tr class='no-items visible'><td style=\"text-
align:left;\"colspan=\"32\">No items<\/td><\/tr>").appendTo(this);
}
});

// Applies styles to datatables.


$(".datatable").each(function () {
$(this).find("tr:first th").addClass("top");
$(this).find("tr:last td").addClass("bottom");
$(this).find("tr:odd td").addClass("dark");
$(this).find("tr td:first-child, tr th:first-
child").addClass("left");
$(this).find("tr td:last-child, tr th:last-
child").addClass("right");
});

$(".datatable [Link]").each(function () {
$(this).bind("sortEnd", function () {
$(".datatable").each(function () {
$(this).find("th, td")
.removeClass("top").removeClass("bottom")
.removeClass("left").removeClass("right")
.removeClass("dark");
$(this).find("tr:first th").addClass("top");
$(this).find("tr:last td").addClass("bottom");
$(this).find("tr:odd td").addClass("dark");
$(this).find("tr td:first-child, tr th:first-
child").addClass("left");
$(this).find("tr td:last-child, tr th:last-
child").addClass("right");
});
});
});
}
});
</script>
</div>
</div>
<script type="application/javascript">
$(function() {
$(".userListMarker").click(function() {
$.post("/data/lists", {action: "findTouched"}, function(json) {
[Link](".userListsFacebox");
var tbody = $("#facebox tbody");
[Link]();
for (var i in json) {
[Link](
$("<tr></tr>").append(
$("<td></td>").attr("data-readKey",
json[i].readKey).text(json[i].name)
)
);
}
[Link]();
[Link]("td").css("cursor", "pointer").click(function() {
[Link] =
[Link]([Link], "list", $(this).attr("data-
readKey"));
});
}, "json");
});
});
</script>
</div>

<div id="datepick-div" style="display: none;"></div><div id="cboxOverlay"


style="display: none;"></div><div id="colorbox" class="" style="display: none;
padding-bottom: 42px; padding-right: 42px;"><div id="cboxWrapper"><div><div
id="cboxTopLeft" style="float: left;"></div><div id="cboxTopCenter" style="float:
left;"></div><div id="cboxTopRight" style="float: left;"></div></div><div
style="clear: left;"><div id="cboxMiddleLeft" style="float: left;"></div><div
id="cboxContent" style="float: left;"><div id="cboxLoadedContent" style="width:
0px; height: 0px; overflow: hidden; float: left;"></div><div
id="cboxLoadingOverlay" style="float: left;"></div><div id="cboxLoadingGraphic"
style="float: left;"></div><div id="cboxTitle" style="float: left;"></div><div
id="cboxCurrent" style="float: left;"></div><div id="cboxNext" style="float:
left;"></div><div id="cboxPrevious" style="float: left;"></div><div
id="cboxSlideshow" style="float: left;"></div><div id="cboxClose" style="float:
left;"></div></div><div id="cboxMiddleRight" style="float: left;"></div></div><div
style="clear: left;"><div id="cboxBottomLeft" style="float: left;"></div><div
id="cboxBottomCenter" style="float: left;"></div><div id="cboxBottomRight"
style="float: left;"></div></div></div><div style="position: absolute; width:
9999px; visibility: hidden; display: none;"></div></div><div style="position:
absolute; width: 0px; height: 0px; overflow: hidden; padding: 0px; border: 0px;
margin: 0px;"><div id="MathJax_Font_Test" style="position: absolute; visibility:
hidden; top: 0px; left: 0px; width: auto; min-width: 0px; max-width: none; padding:
0px; border: 0px; margin: 0px; white-space: nowrap; text-align: left; text-indent:
0px; text-transform: none; line-height: normal; letter-spacing: normal; word-
spacing: normal; font-size: 40px; font-weight: normal; font-style: normal; font-
size-adjust: none; font-family: MathJax_Math-italic,
sans-serif;"></div></div></body></html>

You might also like