1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Luba_88 [7]
3 years ago
8

We use _____command to get data from the user? (python)

Computers and Technology
1 answer:
Genrish500 [490]3 years ago
5 0

Answer:

INPUT

Explanation:

EXAMPLE PYTHON CODE

_______________________________________________________

INPUT CODE:

_______________________________________________________

foo = input('foo: ')#Have some text printed before the input field

bar = foo

print(bar)

_______________________________________________________

OUTPUT CODE:

_______________________________________________________

foo: Hello World!

Hello World!

>>> bar

'Hello World!'

>>>foo

'Hello World!'

You might be interested in
Write a C program (doublecopy) that allows a user to extract some part of an existing file (fileSource) and copy it twice to a n
Slav-nsk [51]

Answer:

Check the explanation

Explanation:

#include <stdio.h>

#include <sys/stat.h>

#include <stdlib.h>

#include <fcntl.h>

#include <errno.h>

#include <unistd.h>

extern int errno;

struct stat st;

int main(int argc, char **argv){

  int num1 = atoi(argv[1]); // Getting num1 from user

  int num2 = atoi(argv[2]); // Getting num2 from user

  char *fileSource = argv[3];

  char *fileTarget = argv[4];

 

  int source_fd = open(fileSource, O_RDONLY); // opening the file in read only mode

  int target_fd = open(fileTarget, O_WRONLY | O_CREAT); // opening the target file in Writeonly mode if file is not found it will create

   

  char *ch = (char *) calloc(num2+num1, sizeof(char));

 

  stat(fileSource, &st);

  if(st.st_size < (num1 + num2)){

      printf("File Size is smaller than the specified bytes\n");

      read(source_fd, ch, st.st_size); // reading the file upto the end

      write(target_fd, ch, st.st_size); // write to the file

      write(target_fd, ch, st.st_size); // two times writing to the file

  }else{

      if(lseek(source_fd, (off_t)num1, SEEK_SET) < 0 ) // moving the cursor to after the specified bytes from the start

      {

          printf("Some Error occured while seeking the file");

          return -1;

      }

      read(source_fd, ch, num2); // reading num2 bytes from the source

      write(target_fd, ch, num2); // writing two times to the target

      write(target_fd, ch, num2);

     

  }

 

  return 0;

 

}

1 2 #include <stdio.h> #include <sys/stat.h> #include <stdlib.h> #include <fcntl.h> #include <errno.h> #include <unistd.h> 4

The code screenshot and code output are attached below.

3 0
2 years ago
The true or false questions.
DIA [1.3K]

Answer:

true

Explanation:

The command:

find -empty -type f -exec rm { } \;

carries out the following steps.

1) Finds all the empty files in the current directory and its subdirectories.

2) For each of the identified files, it executes the command specified as the parameter to exec option,namely, rm <filename>.

So effectively it removes all empty files in the directory tree starting at the current directory.  

7 0
3 years ago
A person who has a been exposed to technology at a young age is?
Dahasolnce [82]
Ok if lets say a young child at the age of like 6-7 was allowed to play grand theft auto by his/her parents maybe the child would understand incorrectly and start doing what the people do in the game this may cause to serious trouble jail time or even death. In this case dont let your kids play underrated games or watch underrated movies.
Hope that helped you understand more.
7 0
3 years ago
A cyber community is different than a physical community because _________________. A.people can go to restaurants to meet frien
jeka94
I believe the question is asking which of the options is true about a cyber community. In that case, only D is true, as a cyber community, such as facebook or instagram, gives you that ability. The rest of the options only apply to a physical community.
7 0
3 years ago
Write a statement that declares a prototype for a function printArray, which has two parameters. The first parameter is an array
Savatey [412]

Answer:

void printArray(int [],int);

Hope this helps!

4 0
2 years ago
Other questions:
  • Write Java program to allow the user to input the amount of deposit, yearly interest rate (percentage), and income tax(percentag
    9·1 answer
  • The part of the computer that contains the brain, or central processing unit, is also known as the
    15·1 answer
  • There are types of templates​
    5·1 answer
  • How do i dos someone? I wanna mess with my friend
    10·1 answer
  • In what way , if any, can your social media presence affect your chances of getting a job in social media?
    8·1 answer
  • What is the exclusive legal right granted to all authors and artists that gives them sole ownership of their work to print, publ
    5·2 answers
  • Describe the major elements and issues with system prototyping​
    7·1 answer
  • What is the output of this program? Assume the user enters 2, 5, and 10.
    6·1 answer
  • 6
    9·1 answer
  • ¿Por qué disminuyó el tamaño de la población de caribús? Usa la evidencia inicial para explicar por qué disminuyó el tamaño de l
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!