This quiz focuses on FlowRow and FlowColumn composables in Jetpack Compose. These components provide a flexible way to organize dynamic content in rows and columns, adapting smoothly to changes in content size and screen orientation. Unlike the more rigid Row and Column layouts, FlowRow and FlowColumn enable items to flow into new rows or columns when space runs out, making them ideal for responsive design. The questions will cover the configuration of Flow layouts, including arrangement options, alignment, item sizing, and the benefits of using Flow composables for dynamic layouts.
1.
How do you control the spacing between items in a FlowColumn along the vertical axis?
2.
How do you ensure a FlowColumn item takes up 50% of the column width?
3.
Which property would you use to limit the number of items in a single row of a FlowRow?
4.
What does the align() modifier do when used in a FlowRow?
5.
Which parameter of FlowRow controls the spacing between items along the horizontal axis?
6.
What happens if a FlowRow item with fillMaxWidth(0.7f) does not have enough space to fit in the current row?
7.
How can you make an item in a FlowRow occupy all the remaining space in a row?
8.
Which arrangement property would you use to position FlowColumn items at the bottom of the column?
9.
Which modifier is useful for aligning items within a FlowColumn when items have different widths?
10.
What effect does the weight() modifier have in a Flow layout?
11.
What does the fillMaxHeight() modifier do when applied to a FlowColumn item?
12.
How do FlowRow and FlowColumn improve upon Row and Column in Compose?
13.
Which arrangement option evenly distributes space between items in a FlowRow without extra space at the ends?
14.
What is the purpose of the horizontalArrangement parameter in a FlowColumn?
15.
Which of the following alignments would center items vertically within a FlowRow?
16.
Which of the following best describes the behavior of FlowRow and FlowColumn?
17.
What property of FlowColumn controls the maximum number of items that can appear in a single column?
18.
What is the primary difference between Row/Column and FlowRow/FlowColumn composables?
19.
What happens if you do not set a limit for maxItemsInEachRow in a FlowRow?
20.
In which scenario is a FlowRow composable preferred over a Row?