Category "types"

Convert python int into int16_t type

I know that python int can be converted into an c int type using ctypes.But how do I convert a python int into an int16_t type? I have tried: import ctypes as

Convert python int into int16_t type

I know that python int can be converted into an c int type using ctypes.But how do I convert a python int into an int16_t type? I have tried: import ctypes as

Why is Boolean's size in vba 2 Bytes?

In my apprenticeship we started doing now vba at school. When our teacher handed us out the data type summary, I was kind of confused. ..... Boolean -> 2

Possible to enforce type hints?

Is there any advantage to using the 'type hint' notation in python? import sys def parse(arg_line: int) -> str: print (arg_line) # passing a string, retu

YAML equivalent of array of objects in JSON

I have a JSON array of objects that I'm trying to convert to YAML. {"AAPL": [ { "shares": -75.088, "date": "11/27/2015" }, { "shares": 75.08

Class cannot find another class in the same namespace

I have a C# WebApp that we are doing for a client. I have two classes in the project, defined (in separate files) as such... A general utility library: name

Does a constructor has a "type" in C++ since it is a special member function

I recently learnt that constructors do not have names in C++ and some other things about them. I am also aware that a function has a type in C++ called a functi

How to docstring kwargs and their expected types

What is the conventional way to express in a docstring the expected types of keyword arguments? Or is this out of principle something I should not be doing at

TypeScript: problems with type system

I'm just testing typescript in VisualStudio 2012 and have a problem with its type system. My html site has a canvas tag with the id "mycanvas". I'm trying to dr

Can I change a table from internal to external in hive?

I created a table in hive as a managed table, but it was supposed to be external, is it possible to change the table type of the table without losing the data?

How to determine if a type is a type of collection?

I am trying to determine if a runtime type is some sort of collection type. What I have below works, but it seems strange that I have to name the types that I b

Auto increment table column

Using Postgres, I'm trying to use AUTO_INCREMENT to number my primary key automatically in SQL. However, it gives me an error. CREATE TABLE Staff ( ID

String[] cannot be converted to int by method invocation conversion?

What this code is trying to do Desired result: Solove the following word problem, using code: Also, you can use the modulus operator to extract the rightmost d

Is there a multivalued field type available in PostgreSQL?

I want to know if it is possible to store multiple values in a field in PostgreSQL. I have a table called Token with the columns id, text and category. categor

Convert float to String and String to float in Java

How could I convert from float to string or string to float? In my case I need to make the assertion between 2 values string (value that I have got from table)

One type is coerced into another, can a method to determine the type of the receiver?

If types T1 and T2 are based on type T, and type T only comes into existence from a NewT1() or NewT2(), is there any way a function func (*T) WhoAmI() can know

C: Custom strlen() library function

I created my version of strlen() function. unsigned int my_strlen(char *p) { unsigned int i = 0; while(*p!='\0') { i++; p++; }

OCaml explicit type signatures

In Haskell, it is considered good practice to explicitly declare the type signature of your functions, even though it can (usually) be inferred. It seems like t

How to avoid this kind of notation " | undefinded " in typescript?

It's not essential, but I'm asking out of curiosity. In Object type we can declare optional property by using ?: operator, but is there a similar shorthand when

Limit file format when using <input type="file">?

I'd like to restrict the type of file that can be chosen from the native OS file chooser when the user clicks the Browse button in the <input type="file">