Looking for Redes de Computadores-B_EINF_2 test answers and solutions? Browse our comprehensive collection of verified answers for Redes de Computadores-B_EINF_2 at www.moodle.uevora.pt.
Get instant access to accurate answers and detailed explanations for your course questions. Our community-driven platform helps students succeed!
Português: No trabalho prático (leilões UDP), quando um lance é aceite por ser superior ao lance actual mais alto, o servidor deve transmitir a mensagem NEWHIGH <auctionID> <value> <bidder> a todos os participantes desse leilão.
Assumindo que o servidor mantém uma lista de estruturas com os endereços (IP e porta) de cada cliente inscrito num dado leilão, escreva um trecho de código em C (ou pseudocódigo) que percorra essa lista e envie a mensagem NEWHIGH a todos os participantes (incluindo ou não o próprio licitador – a decisão é sua, mas justifique brevemente). Utilize a função sendto() para UDP.
English: In the practical work (UDP auctions), when a bid is accepted because it is higher than the current highest bid, the server must broadcast the message NEWHIGH <auctionID> <value> <bidder> to all participants of that auction.
Assuming the server maintains a list of structures containing the addresses (IP and port) of each client subscribed to a given auction, write a code snippet in C (or pseudocode) that iterates over that list and sends the NEWHIGH message to all participants (including or not the bidder itself – your choice, but briefly justify). Use the sendto() function for UDP.
Nota: Não é necessário incluir o código completo do servidor, apenas a função ou o bloco que efetua o broadcast.Note: You do not need to include the full server code, only the function or block that performs the broadcast.
Port.: Explique sucintamente a diferença entre Congestion Window (cwnd) e Receiver Window (rwnd) no contexto do controlo de saturação TCP. Como o emissor combina estes dois valores?
Eng.: Briefly explain the difference between Congestion Window (cwnd) and Receiver Window (rwnd) in TCP congestion control. How does the sender combine these two values?
Português: No enunciado do trabalho prático (leilões UDP), existem duas formas distintas de um leilão terminar. Descreva‑as por palavras suas, explicando sucintamente o que acontece em cada caso (quem inicia o término, o que é anunciado, e qual o destino do leilão).
English: In the practical work statement (UDP auctions), there are two distinct ways for an auction to end. Describe them in your own words, briefly explaining what happens in each case (who initiates the termination, what is announced, and what is the fate of the auction).
Resposta esperada: entre 3 a 6 linhas. Não é necessário código.Expected answer: 3 to 6 lines. No code required.
Port.: Na ficha_7, para guardar as respostas de uma pergunta, a estrutura mais adequada (em C) deve conter, no mínimo:Eng.: In sheet_7, to store the answers of a given question, the most appropriate C structure must contain at least:
Port.: No servidor multi‑cliente da ficha_6, quando um cliente envia a mensagem IAM userX, o servidor deve:Eng.: In the multi‑client server from sheet_6, when a client sends the message IAM userX, the server must:
Port.: Um switch Ethernet utiliza inundação (flooding) quando:Eng.: An Ethernet switch uses flooding when:
Port.: O campo TTL no cabeçalho IP serve principalmente para:Eng.: The TTL field in the IP header mainly serves to:
Port.: No TCP Reno, quando ocorre a deteção de perda por 3 ACKs duplicados (triple duplicate ACK), o comportamento correto é:Eng.: In TCP Reno, when loss is detected by triple duplicate ACK, the correct behavior is:
Port.: Relativamente à comutação de circuitos e de pacotes, qual das afirmações é correta?Eng.: Regarding circuit switching and packet switching, which statement is correct?
Português: No algoritmo AIMD do TCP, o comportamento de "Aumento Aditivo" (Additive Increase) significa que:
English: In the TCP AIMD algorithm, the "Additive Increase" behavior means that: