Rapport cryptarithm 1.0
Dev-linux
Macros | Functions
code.c File Reference

Mon code pour cryptarithm. More...

#include <stdio.h>
#include <string.h>
#include <stdlib.h>
Include dependency graph for code.c:

Go to the source code of this file.

Macros

#define MAX_LETTRES   10
 
#define MAX_MOTS   5
 
#define MAX_LONGUEUR   100
 

Functions

int verifier_solution (char mots[MAX_MOTS][MAX_LONGUEUR], int N, char totalStr[MAX_LONGUEUR], int chiffres[], char lettres[], int nb_lettres)
 vérifie si la combinaison satisfait l'addition More...
 
void permuter (int chiffres[], int index, int utilisé[], char mots[MAX_MOTS][MAX_LONGUEUR], int N, char totalStr[MAX_LONGUEUR], char lettres[], int nb_lettres)
 génère les permutations des chiffres More...
 
int main ()
 

Detailed Description

Mon code pour cryptarithm.

Author
Eliott
ESBELIN
Version
finale
Date
20 avril 2025

Definition in file code.c.

Macro Definition Documentation

◆ MAX_LETTRES

#define MAX_LETTRES   10

Definition at line 19 of file code.c.

◆ MAX_LONGUEUR

#define MAX_LONGUEUR   100

Definition at line 33 of file code.c.

◆ MAX_MOTS

#define MAX_MOTS   5

Definition at line 26 of file code.c.

Function Documentation

◆ main()

int main ( )

Definition at line 113 of file code.c.

Here is the call graph for this function:

◆ permuter()

void permuter ( int  chiffres[],
int  index,
int  utilisé[],
char  mots[MAX_MOTS][MAX_LONGUEUR],
int  N,
char  totalStr[MAX_LONGUEUR],
char  lettres[],
int  nb_lettres 
)

génère les permutations des chiffres

Parameters
chiffresun tableau d'entier naturel
indexun entier naturel
utiliséun tableau d'entier naturel
motsun tableau de chaines de caractères
Nun entier naturel
totalStrune chaine de caractère
lettresune chaine de caractère
nb_lettresun entier naturel

Definition at line 81 of file code.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ verifier_solution()

int verifier_solution ( char  mots[MAX_MOTS][MAX_LONGUEUR],
int  N,
char  totalStr[MAX_LONGUEUR],
int  chiffres[],
char  lettres[],
int  nb_lettres 
)

vérifie si la combinaison satisfait l'addition

Parameters
motsun tableau de chaines de caractères
Nun entier naturel
totalStrune chaine de caractères
chiffresun entier naturel
lettresune chaine de caractère
nb_lettresun entier naturel
Returns
1 si l'addition est correcte
0 si l'addition n'est pas correcte

Definition at line 48 of file code.c.

Here is the caller graph for this function: