This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Curso de Bacharelado em Ciência da Computação - IFSul Passo Fundo | |
* Compiladores - 2021/1 | |
* Willian R. Schuck | |
* Construção de parser para a gramática: | |
* A' -> A | |
* A -> (A) | a | |
* */ | |
#include <stdio.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.BufferedReader; | |
import java.io.PrintStream; | |
public class Cliente { | |
private static int sequenceId = 1; | |
private Integer id; | |
private String ip; | |
private String nome; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package br.edu.ifsul.so2; | |
public class Main { | |
public static void main(String[] args) { | |
// Comente as linhas para testar individualmente | |
testeRunnable(); | |
testeThread(); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#define swap(a, b) {int aux = a; a = b; b = aux;} | |
void quicksort(int*, int, int); | |
int partition(int*, int, int); | |
int main() { | |
int a[] = {10,9,8,7,6,5,4,3,2,1}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<persistence | |
xmlns="http://java.sun.com/xml/ns/persistence" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence | |
http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd" | |
version="2.0"> | |
<!-- O nome da unidade de persistência que o EntityManager irá buscar --> | |
<persistence-unit name="nome-da-unidade-de-persistencia"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!ELEMENT pessoas (pessoa*)> | |
<!ELEMENT pessoa (nome, endereco, salario, sexo, email, telefones)> | |
<!ATTLIST pessoa codigo CDATA #REQUIRED> | |
<!ELEMENT nome (#PCDATA)> | |
<!ELEMENT endereco (#PCDATA)> | |
<!ELEMENT salario (#PCDATA)> | |
<!ELEMENT sexo (#PCDATA)> | |
<!ELEMENT email (#PCDATA)> | |
<!ELEMENT telefones (numero*)> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> | |
<!-- Utilizando facetas, faça as restrições necessárias para os campos: pessoas | |
(nome, salario, sexo e e-mail) e telefones(numero). --> | |
<xs:element name="pessoas"> | |
<xs:complexType> | |
<xs:sequence> | |
<xs:element ref="pessoa" minOccurs="0" maxOccurs="unbounded"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
struct MinhaStruct { | |
int chave; | |
}; | |
/* | |
Os operadores de comparação não são gerados quando a struct é definida. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <windows.h> | |
#include <cstdio> | |
using namespace std; | |
typedef int tipochave; | |
typedef struct aux { | |
tipochave chave; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from bs4 import BeautifulSoup | |
import getpass | |
import requests | |
import re | |
import os | |
urlLogin = 'https://moodle.passofundo.ifsul.edu.br/login/index.php' | |
def getPageContent(url): | |
return s.get(url).text |
NewerOlder