
Uso de Arquivos em Python
Authored by Luciano Topolniak
Information Technology (IT)
10th Grade
Used 3+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 10 pts
Qual é o modo padrão de abertura de arquivos em Python usando a função `open()`?
'w'
'r'
'a'
'x'
2.
MULTIPLE CHOICE QUESTION
30 sec • 10 pts
O que acontece se você tentar abrir um arquivo inexistente no modo 'r'?
O arquivo é criado automaticamente.
Um erro do tipo FileNotFoundError é lançado.
O arquivo é aberto em branco.
O Python ignora a operação.
3.
MULTIPLE CHOICE QUESTION
30 sec • 10 pts
Qual é a principal vantagem de usar o bloco `with` ao trabalhar com arquivos em Python?
Permite abrir vários arquivos ao mesmo tempo.
Garante o fechamento automático do arquivo após o uso.
Torna o código mais lento.
Permite modificar arquivos somente para leitura.
4.
MULTIPLE CHOICE QUESTION
30 sec • 10 pts
Qual dos modos abaixo permite adicionar conteúdo ao final de um arquivo sem apagar o conteúdo existente?
'w'
'r'
'a'
'x'
5.
MULTIPLE CHOICE QUESTION
30 sec • 10 pts
Após abrir um arquivo com `open('arquivo.txt', 'w')`, o que acontece com o conteúdo anterior do arquivo?
O conteúdo anterior é mantido.
O conteúdo anterior é apagado.
O arquivo é renomeado.
O arquivo é movido para outra pasta.
6.
MULTIPLE CHOICE QUESTION
30 sec • 10 pts
Qual comando é utilizado para fechar um arquivo manualmente em Python?
file.close()
file.end()
file.stop()
file.quit()
7.
MULTIPLE CHOICE QUESTION
30 sec • 10 pts
O que acontece se você tentar ler um arquivo já fechado?
O Python lê normalmente.
Um erro do tipo ValueError é lançado.
O arquivo é reaberto automaticamente.
O conteúdo é retornado como uma string vazia.
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
15 questions
Eval. 3B Bloque 1
Quiz
•
9th Grade - University
15 questions
Se liga 3º trimestre 1º ano
Quiz
•
10th Grade
10 questions
Quiz aula 8
Quiz
•
9th - 12th Grade
10 questions
Aula 5
Quiz
•
9th - 12th Grade
15 questions
STP_Integrasi aplikasi
Quiz
•
9th Grade - University
15 questions
Excel Funksiyalari Bo'yicha Savollar
Quiz
•
10th Grade
11 questions
HARDWARE, SOFTWARE E PERIFÉRICOS
Quiz
•
10th Grade
15 questions
Quiz sobre Hardware e Software
Quiz
•
2nd Grade - University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
Discover more resources for Information Technology (IT)
20 questions
-AR -ER -IR present tense
Quiz
•
10th - 12th Grade
10 questions
Understanding Meiosis
Interactive video
•
6th - 10th Grade
15 questions
Main Idea and Supporting Details.
Quiz
•
4th - 11th Grade
20 questions
Cell Organelles
Quiz
•
10th Grade
25 questions
Complementary and Supplementary Angles
Quiz
•
7th - 10th Grade
12 questions
Add and Subtract Polynomials
Quiz
•
9th - 12th Grade
13 questions
Model Exponential Growth and Decay Scenarios
Quiz
•
9th - 12th Grade
10 questions
Exploring the Layers of the Earth
Interactive video
•
6th - 10th Grade