What you want is the following:
DEFINITION A set $D\subseteq \Bbb R$ is dense over $\Bbb R$ if for every $x\in \Bbb R$ there exists a sequence $\{x_n\}\subset D$ such that $x_n\to x$.
DEFINITION Given a function $f:X\to Y$, the restriction of $f$ to $D\subset X$ is the function $f\mid _D:D\to Y$ such that $f\mid_D(x)=f(x)$ for each $x\in D$.
THEOREM Let $f$ and $g$ be continuous over $\Bbb R$. Let $D$ be dense over $\Bbb R$. If $f\mid_D=g\mid_D$, then $f=g$. That is, if $g$ and $f$ agree on every point of $D$, then they agree on every point of $\Bbb R$.
PROOF Let $x\in \Bbb R\setminus D$. Then there exists a sequence $\{x_n\}\subset D$ such that $x_n\to x$. And for this sequence $\lim\; f(x_n)=f(x)=g(x)=\lim\; g(x_n)$, so the claim follows. Note that since $\{x_n\}\subset D$, $x_n\neq x$ for each $n$.
The proof is rather simple if you have already characterized continuity in terms of sequences, that is
PROPOSITION Let $f:[a,b]\to \Bbb R$ be continuous. Then $f$ is continuous if, and only if, for each sequence $\{x_n\}\subset [a,b]$ such that $x_n\to x$ (with $x\neq x_n$ for each $n$) we have that $f(x_n)\to f(x)$.
PROOF Suppose $f$ is continuous, and $x_n\to x$. Then for each $ \epsilon>0$ we get a $\delta >0$ such that for each $y$, whenever $|x-y|<\delta$, $|f(x)-f(y)|<\epsilon$. Since $x_n\to x$, we can obtain an $N$ such that if $n>N$, then $|x-x_n|<\delta$, so that for $n>N$; $|f(x)-f(x_n)|<\epsilon$, and one direction follows. Can you prove the other direction?