All Questions

1
answer

Is there any pythonic way to slice an array?

In JavaScript there is Array.prototype.slice : var input = [ 'laranja', 'limão', 'melancia', 'mamão' ]; var aparada = input.slice(1, -1); console.log( aparada ); And in PHP array_slice : $input = arr...
asked on 24.12.2017 / 20:00
2
answers

Problem with nth-child

I have the following scenario: HTML: <div class='linha visivel'>Visivel</div> <div class='linha visivel'>Visivel</div> <div class='linha oculto' style='display:none'>Invisivel</div> <div class='linha v...
asked on 27.02.2015 / 18:40
1
answer

C # WinForms - ComboBox that autocompletes (filters) as you type

I have a ComboBox (cmbBairro) with the names of the neighborhoods of my city, which loads the values of a List (_ListBairros). When the user tries to search for a neighborhood by typing, I would like the ComboBox values to be filtered, regardles...
asked on 09.03.2015 / 02:20
1
answer

What are the implementation differences between the Browser console and the NodeJS console?

Yesterday I was using a MooTools class in NodeJS and I encountered strange behavior in console.log of NodeJS. The code works beautifully but the console does not show what I know is there. For example doing: function FN(nome) { t...
asked on 07.04.2015 / 08:52
1
answer

How to create a plot with 2 superimposed histograms?

Suppose I have the following data from 2 distinct groups. set.seed(1) grupo1<-rnorm(400,6,2) grupo2<-rnorm(200,8,2) How do I make a histogram of the two groups on the same screen, identifying each of the groups with a distinct color a...
asked on 21.02.2014 / 01:11
2
answers

Queries between tables with Eloquent - Laravel 5

Well, I have the following problem when using Laravel 5 in the table relationship: I have these 4 tables (hypothetical names to illustrate the problem): UsingtheLaravel5templatesI'velistedthemtogether:CompanyTemplatepublicfunctionpessoa(){...
asked on 21.03.2015 / 22:04
1
answer

How to fix rigid "bodies" using PhysX

How can I fix two hard or dynamic "bodies" in a way that where one goes the other goes as close as possible to PhysX . I'm using the PxFixedJoint class but it did not please me. Asyoucanseeintheprintabove,thereisa"belly" curve in t...
asked on 31.07.2014 / 19:59
3
answers

Several tables that should represent a single entity

I'm updating a system that has eleven tables that represent a single entity, I believe by implementation error, as shown below: Entidade: Foo Tabela Foo1 - Campo1, Campo2, Campo3 Tabela Foo2 - Campo1, Campo2, Campo3 Tabela Foo3 - Campo1, Camp...
asked on 13.02.2015 / 13:13
3
answers

Change CRT file to byte

I need to convert a file .crt to byte so I can send it by socket. This code works in Java, but how would I write it on Android? Path path = Paths.get("sdcard/certificado.crt"); byte[] certificado = Files.readAllBytes(path);     
asked on 16.03.2014 / 13:06
1
answer

When to use Supertype or Subtype on return method?

Suppose I have a method called " meuMetodo() " that returns an Object of type ArrayList<String> , I can make this method declare that it returns more concrete or more abstract types:    public ArrayList<String> meu...
asked on 10.05.2017 / 22:08