precision ok, width en cours

This commit is contained in:
Hugo LAMY
2020-02-24 16:09:13 +01:00
parent 42b90aabb2
commit af53304947
6 changed files with 154 additions and 111 deletions

View File

@@ -6,7 +6,7 @@
/* By: hulamy <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/02/19 16:23:01 by hulamy #+# #+# */
/* Updated: 2020/02/20 13:03:34 by hulamy ### ########.fr */
/* Updated: 2020/02/24 14:34:16 by hulamy ### ########.fr */
/* */
/* ************************************************************************** */

View File

@@ -6,7 +6,7 @@
/* By: hulamy <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/02/10 13:58:30 by hulamy #+# #+# */
/* Updated: 2020/02/10 16:36:35 by hulamy ### ########.fr */
/* Updated: 2020/02/24 14:33:47 by hulamy ### ########.fr */
/* */
/* ************************************************************************** */
@@ -26,12 +26,8 @@ int width_precision(char *s)
i = 0;
if (ft_strchr("*", s[i]) != NULL)
i++;
else if (ft_strchr("123456789", s[i]) != NULL)
{
while (ft_strchr("0123456789", s[i]) != NULL)
i++;
while (ft_strchr("0123456789", s[i]) != NULL)
i++;
}
return (i);
}