Skip to content

Instantly share code, notes, and snippets.

@fmstefanini
fmstefanini / rails_server.log
Created December 7, 2015 19:30
Rails Server log when accessing Discourse's topic with a logged user
D, [2015-12-07T19:26:57.569623 #3118] DEBUG -- : SQL (3.0ms) UPDATE "users" SET "last_seen_at" = '2015-12-07 19:26:57.545642' WHERE "users"."id" = 168964 [["id", 168964]]
D, [2015-12-07T19:26:57.576431 #3118] DEBUG -- : Draft Load (0.9ms) SELECT "drafts".* FROM "drafts" WHERE "drafts"."user_id" = 168964 AND "drafts"."draft_key" = 'new_topic' LIMIT 1 [["user_id", 168964], ["draft_key", "new_topic"]]
D, [2015-12-07T19:26:57.580172 #3118] DEBUG -- : TopicUser Load (1.0ms) SELECT "topic_users".* FROM "topic_users" WHERE "topic_users"."user_id" = 168964 AND "topic_users"."topic_id" IN (8, 10, 9, 7, 6, 5, 4, 295883, 23349, 142710, 142709, 291299, 23352, 295882, 35948, 76827, 222553, 94613, 237990, 237993, 94658, 94648, 94649, 23353, 94654, 142708, 295876, 94652, 94656, 94650) [["user_id", 168964]]
D, [2015-12-07T19:26:57.584594 #3118] DEBUG -- : User Load (1.5ms) SELECT "users"."id", "users"."email", "users"."username", "users"."uploaded_avatar_id" FROM "users" WHERE "users"."id" IN (-1, 40438, 1672
/*Criar um programa que perco1rra uma matriz e
a preencha, a partir do número 1, de forma
espiral. A entrada do programa será o número
de linhas e o número de colunas da matriz.
Este problema é mais fácil de ser
compreendido através de exemplos:
Entrada: 4 3
Saída:
1 2 3
10 11 4
public class FatoresPrimos {
static int x = 0;
static int y = 11;
static boolean ehprimo=true;
static boolean verificar(int y){
//Correção do código feita pelo monitor, reatribuição do valor true para a variável ehprimo;
ehprimo = true;
// Escrever um programa que apresente os nomes de todos os meses do ano, a
// esta��o do ano a que pertencem e o n.� de dias de cada m�s, usando array
import java.util.Scanner;
public class DojoCalendario {
public static void main (String[] args){
Scanner e = new Scanner(System.in);
int mes = e.nextInt();
public class Olamundo {
static String teste = "123";
public static void main (String[] args) {
//System.out.println (teste);
//String teste = "123";
System.out.println("Ola Mundo");
//System.out.println(escrever ());
escrever ("eba");
}
public static void escrever (String frase){
public class VerificadorVeiculo {
public static void main (String[] args) {
//VerificadorVeiculo joao = new VerificadorVeiculo();
//joao.veiculo (2, 1, 3);
//System.out.println(args[0]);
int x[] = {Integer.parseInt(args[0]),Integer.parseInt(args[1]), Integer.parseInt(args[2]), Integer.parseInt(args[3]),Integer.parseInt(args[4]), Integer.parseInt(args[5]) };
veiculo (x[0], x[1], x[2]);
veiculo (x[3],x[4],x[5]);