A00-215 Exam Question 76

You are tasked with analyzing sales data for different regions. You need to calculate the cumulative sum of sales for each region, resetting the sum at the start of each new region. Which of the following code snippets would correctly achieve this, using BY group processing with FIRST. and LAST. to accumulate in groups?
  • A00-215 Exam Question 77

    Consider the following SAS code snippet:

    What is the main logical error in this code?
  • A00-215 Exam Question 78

    You are analyzing a dataset called 'SalesData' with variables 'Region' (character) and 'SalesAmount' (numeric). You need to generate a frequency table that includes both the frequencies and percentages of each 'Region' category, and also display the cumulative frequencies and percentages. Which of the following options is the correct code snippet for this task?
  • A00-215 Exam Question 79

    You have three datasets: 'CUSTOMER INFO', 'ORDER DETAILS', and 'PRODUCT_DATA', each containing a unique 'CUSTOMER ID', 'ORDER ID', and 'PRODUCT ID' respectively. You need to create a new dataset 'COMPLETE DATA' that combines the data from all three datasets based on the following logic: 1. Merge 'CUSTOMER INFO' and 'ORDER DETAILS' datasets on 'CUSTOMER ID'. 2. Then, merge the resulting dataset with 'PRODUCT DATA' on 'ORDER ID'. Write the SAS code to achieve this using MERGE statements.
  • A00-215 Exam Question 80

    You have a dataset 'PRODUCTS' with variables 'ProductlD', 'ProductName', and 'Price'. You want to create two new variables: 'DiscountedPrice' and 'DiscountPercentage'. 'DiscountedPrice' should be calculated as 'Price' , 0.9 if 'Price' is greater than 100, and as 'Price' , 0.8 if 'Price' is less than or equal to 100. 'DiscountPercentage' should be calculated as (Original Price - Discounted Price) / Original Price , 100. Which code snippet correctly implements this logic in the DATA step? (Select all that apply)