Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //
- // Created by ppinh on 30/11/2019.
- //
- #ifndef AED_LP1_PROJETO_PROJETO_H
- #define AED_LP1_PROJETO_PROJETO_H
- #define NUM 9
- struct node{
- int data;
- int array[NUM];
- int tam;
- int lin; /// para poder fazer os quadrados(para saber em que posicao estou e percorrer a area certa do quadrado)
- int col;
- struct node *pnext;
- struct node *prev_node;
- struct node *N;
- struct node *S;
- struct node *NO;
- struct node *NE;
- struct node *SO;
- struct node *SE;
- };
- struct tabuleiros{
- struct node *no;
- struct tabuleiros *next,*prev;
- int index;
- };
- struct fila{
- int size;
- struct tabuleiros * tabuleiro;
- struct tabuleiros *inicio, *fim;
- };
- /// fila ///
- void printfila(struct fila *f);
- struct fila * createFila();
- struct fila addFila(struct fila *f, struct node *head);
- ///////
- int main_projeto(int argc, char **argv);
- /// brute force ///
- int verifica_quadrado(struct node *current,int num);
- int verifica_col(struct node *tab,int num);
- int verifica_lin(struct node *tab,int num);
- int verifica_x_principal(struct node *current,int num);
- struct node * encontra_zeros(struct node *tab);
- int verificar_condicoes(struct node * tab,int num);
- int sudoku(struct node *head);
- ///
- int ** matriz_aleatoria();
- void carregar_matriz(struct node **head);
- void imprimirSudoku(struct node *pcs);
- void guardar_matriztxt(struct node * tab);
- void guardar_matrizbin(struct node * tab);
- void verificar_consistencia(int **matriz);
- int ***tabuleirosmemoria(int **matriz, int ***memoria);
- int **resolverONK(int **matriz, int ***memoria);
- /// ALGORITMO DO SUDOKU ///
- void numeros_possiveis(struct node *current);
- void remover_numero(struct node *current,int cel,struct node *head);
- int verifica_oculto(struct node *current,int cel );
- void elimina_par_coluna(struct node *current);
- void elimina_par_linha(struct node *current);
- void elimina_par_diag(struct node *current);
- void elimina_par_diag_secun(struct node *current);
- void elimina_par_quadrado(struct node *current);
- void pares_sozinhos (struct node * current);
- int resolver_matriz(struct node *head);
- int alg_sudoku(struct node **head, int ***memoria);
- ///
- void menu();
- #endif //AED_LP1_PROJETO_PROJETO_H
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement