# How to change the color environment tasks in latex?

\begin{tasks}(3)
$3x^3 - 21x$}
$5x^6 + 15x^4$}
$4x^3 + 10x^2 - 2x$}


I assume that just the math material should be in red. If that's the case, the following code will achieve your formatting-related objective.

\documentclass{article}

\usepackage{etoolbox}

\begin{document}
\task  $3x^3 - 21x$
\task  $5x^6 + 15x^4$
\task  $4x^3 + 10x^2 - 2x$
\end{document}

• Aside: Issue the instruction \settasks{style=enumerate} after loading the tasks package to get the tasks enumerated with arabic numerals followed by a period ("full stop"). – Mico Apr 5 '16 at 5:10

If you want to get the whole task in red, you need a small patch of an internal expl3 code as it currently resets everything to black:

\documentclass{article}

\ExplSyntaxOn\makeatletter
%patch needed to get a around a problem in the l3-drivers
\AtBeginDocument{
\cs_set_protected_nopar:Npn \color_ensure_current:
{\set@color}
}
\ExplSyntaxOff\makeatother

\begin{document}
\begingroup
\color{red}
\task $3x^3 - 21x$
$5x^6 + 15x^4$
\task $4x^3 + 10x^2 - 2x$
\endgroup
\end{document}


Set both the item-format and the label-format.

\documentclass{article}

style = enumerate ,
label-format = \bfseries
}

\begin{document}

% local:
In exercises 1--8, factor the common factor in the polynomials.
\task  $3x^3 - 21x$
\task  $5x^6 + 15x^4$
\task  $4x^3 + 10x^2 - 2x$

% for all lists:
\task  $3x^3 - 21x$
\task  $5x^6 + 15x^4$
\task  $4x^3 + 10x^2 - 2x$