更新された2024年10月合格させるWeb-Development-Applications試験リアル練習テスト問題 [Q41-Q66]

Share

更新された2024年10月合格させるWeb-Development-Applications試験リアル練習テスト問題

無料ダウンロードWGU Web-Development-Applicationsリアル試験問題

質問 # 41
What should a developer increase to create space between a border and content?

  • A. Margin
  • B. Width
  • C. Padding
  • D. Height

正解:C

解説:
Padding is the CSS property used to create space between the content of an element and its border. It is an internal spacing within the element.
* CSS Box Model:
* Content: The innermost part, where text and images appear.
* Padding: The space between the content and the border.
* Border: The edge of the element.
* Margin: The space outside the border, creating space between different elements.
* Usage:
* Padding:
div {
padding: 20px;
}
* This code adds 20 pixels of padding on all sides of the content within the div element.
* References:
* MDN Web Docs - Padding
* W3C CSS Box Model


質問 # 42
A file named application, Appchache contains the following content:

Which attribute should a developer set to application. Appchache so the four files will be cached?

  • A. The src attribute of the <script> element
  • B. The srcset attribute of the <source> element
  • C. The href attribute of the <Link> element
  • D. The manifest attribute of the <html> element

正解:D

解説:
To specify a cache manifest file for an HTML document, the manifest attribute must be set in the <html> element. This attribute tells the browser to cache the files listed in the manifest for offline use.
* Cache Manifest:
* Purpose: Specifies resources that should be cached by the browser.
* Attribute: manifest is used in the <html> tag to link the cache manifest file.
* Example:
* Given the manifest file application.appcache:
CACHE MANIFEST
CACHE:
default.html
stylesheet.css
functions.js
logo.jpg
* HTML with the manifest attribute:
<html manifest="application.appcache">
</html>
* References:
* MDN Web Docs - Offline Web applications
* W3C HTML5 Specification - manifest attribute


質問 # 43
Which 3D transform affects the distance between the z-plane and the user?

  • A.
  • B.
  • C.
  • D.

正解:A

解説:
The perspective(n) method in CSS is used to affect the distance between the z-plane and the user, effectively changing the perspective depth of a 3D transformed element.
* perspective(n) Method: The perspective function defines how far the element is from the user. It affects the appearance of the 3D transformed element, giving it a sense of depth.
* Usage Example:
container {
perspective: 1000px;
}
In this example, the perspective is set to 1000 pixels, which defines the distance between the z-plane and the user.
* Properties:
* n: This represents the perspective distance. The lower the value, the more pronounced the perspective effect.
References:
* MDN Web Docs on perspective
* W3C CSS Transforms Module Level 1


質問 # 44
What does a form field default to if the type attribute is omitted from a form?

  • A. Text
  • B. Range
  • C. number
  • D. Date

正解:A

解説:
If the type attribute is omitted from an <input> element, it defaults to text.
* HTML Input Default Type:
* Default Type: The default value for the type attribute in an <input> element is text.
* Example:
* Given the HTML:
<input>
* This will render as a text input field.
* References:
* MDN Web Docs - <input>
* W3Schools - HTML Input Types


質問 # 45
Which History API object is called when a browser window's document history changes?

  • A. Window, open
  • B. Window, name
  • C. Window, location
  • D. Window, onpopstate

正解:D

解説:
The onpopstate event is triggered in the window object when the active history entry changes, such as when the user navigates to a different page using the back or forward buttons in the browser.
* History API and onpopstate:
* Event: window.onpopstate
* Description: This event is fired when the user navigates to a session history entry, i.e., when moving backwards or forwards in the browser history.
* Example:
window.onpopstate = function(event) {
console.log("location: " + document.location + ", state: " + JSON.stringify(event.state));
};
* Other Options:
* A. Window, location: location is an object containing information about the current URL.
* C. Window, name: name is a property to set or get the name of a window.
* D. Window, open: open is a method to open a new browser window or tab.
* References:
* MDN Web Docs - window.onpopstate
* W3Schools - JavaScript History API


質問 # 46
Given the following CSS code:

Which type of selector is used?

  • A. Class
  • B. Element
  • C. Group
  • D. ID

正解:D

解説:
The given CSS code uses the #name selector, which is an ID selector. The ID selector is used to style an element with a specific id attribute.
* ID Selector: In CSS, the ID selector is used to style the element with the specific id. The syntax for the ID selector is #id, where id is the id attribute value of the HTML element.
* Usage Example:
#name {
text-align: left;
}
This CSS rule will apply the text-align: left; style to the element with id="name".
* ID Selector Characteristics:
* An ID must be unique within a document, meaning it can be used only once per page.
* ID selectors are more specific than class selectors and element selectors.
* Example in HTML:
<div id="name">This is a div with ID "name".</div>
References:
* MDN Web Docs on CSS Selectors
* W3C CSS Specification on Selectors


質問 # 47
Given the following code:

What does the console display as output?

  • A. 0
  • B. 1
  • C. 2

正解:B

解説:
Given the code segment:
var a = "8";
var b = "6";
var c = a + b;
console.log(c);
This code concatenates two strings.
* Explanation:
* var a = "8";: Variable a is assigned the string "8".
* var b = "6";: Variable b is assigned the string "6".
* var c = a + b;: The + operator concatenates the two strings, resulting in "86".
* console.log(c);: Outputs the value of c to the console.
* Output:
* The console displays "86" because it concatenates the two string values.
* References:
* MDN Web Docs - String
* W3Schools - JavaScript String


質問 # 48
Given the following code:

What does the #item token do?

  • A. It locates an HTML5 element by its ID
  • B. It creates an XML element.
  • C. It defines a JavaScript function with one parameter.
  • D. It specifies a CSS3 property.

正解:A

解説:
The #item token in CSS is used to select an HTML element by its ID attribute.
* CSS ID Selector:
* Syntax: The ID selector is prefixed with a hash symbol (#) followed by the ID value of the HTML element.
* Example: If the HTML element has an attribute id="item", it can be selected and styled in CSS as:
width: 300px;
}
* Functionality:
* Selects an Element: The ID selector targets the specific HTML element with the matching id attribute.
* Specificity: ID selectors have high specificity, meaning they will override styles from type selectors and


質問 # 49
What is the effect of using the in-line validation process during user input?

  • A. Slower rate of form completion
  • B. Larger number of errors created
  • C. Increased computation on the server
  • D. More successful form completion rates

正解:D

解説:
Inline validation during user input provides immediate feedback to the user about the correctness of their input. This real-time feedback helps users correct mistakes as they go, leading to higher rates of successful form completion.
* Inline Validation: Inline validation refers to checking the validity of input data as it is entered, rather than waiting until the form is submitted. This helps users to receive immediate feedback and correct errors on the spot.
* Benefits:
* Immediate Feedback: Users can correct mistakes immediately, which helps reduce frustration and confusion.
* Increased Success Rates: By providing real-time feedback, users are more likely to complete the form correctly, resulting in higher completion rates.
* User Experience: Improves the overall user experience by making the process more interactive and user-friendly.
References:
* Nielsen Norman Group on Inline Validation
* MDN Web Docs on Constraint Validation


質問 # 50
Which feature was introduced in HTML5?

  • A. Addition of CSS in the HTML file
  • B. Native drag-and-drop capability
  • C. Adherence to strict XML syntax rules
  • D. Ability to hyperlink to multiple web pages

正解:B

解説:
HTML5 introduced several new features that enhanced web development capabilities significantly. One of the notable features is the native drag-and-drop capability.
* Native Drag-and-Drop Capability:
* Description: HTML5 allows developers to create drag-and-drop interfaces natively using the draggable attribute and the DragEvent interface. This means elements can be dragged and dropped within a web page without requiring external JavaScript libraries.
* Implementation:
* Making an Element Draggable: To make an element draggable, you set the draggable attribute to true:
<div id="drag1" draggable="true">Drag me!</div>
* Handling Drag Events: You use event listeners for drag events such as dragstart, dragover, and drop:
document.getElementById("drag1").addEventListener("dragstart", function(event) { event.dataTransfer.setData("text", event.target.id);
});
document.getElementById("dropzone").addEventListener("dragover", function(event) { event.preventDefault();
});
document.getElementById("dropzone").addEventListener("drop", function(event) { event.preventDefault(); var data = event.dataTransfer.getData("text"); event.target.appendChild(document.getElementById(data));
});
* Example: This example demonstrates a simple drag-and-drop operation:
html
Copy code
<div id="drag1" draggable="true">Drag me!</div>
<div id="dropzone" style="width: 200px; height: 200px; border: 1px solid black;">Drop here</div>
* References:
* W3C HTML5 Specification - Drag and Drop
* MDN Web Docs - HTML Drag and Drop API
* HTML5 Doctor - Drag and Drop
HTML5's native drag-and-drop feature streamlines the process of creating interactive web applications by eliminating the need for third-party libraries, thus making it a powerful addition to the HTML standard.


質問 # 51
Which HTML segment should a developer use to enable the Offline AppCache application interface (API)?

  • A.
  • B.
  • C.
  • D.

正解:D

解説:
The correct HTML segment to enable the Offline AppCache application interface (API) is by specifying the manifest attribute in the <html> tag.
* AppCache Manifest: The manifest attribute in the <html> tag is used to specify the URL of the AppCach


質問 # 52
Given the following javaScript code:

Which code segment calls the method?

  • A. Window,sayhello();
  • B. Obj,sayHello;

正解:B

解説:
To call the sayHello method in the given JavaScript object, you need to use the object's name followed by the method name with parentheses.
* Correct Method Call:
* Given the object definition:
var obj = {
sayHello: function() {
alert("Hello");
}
};
* To call the method sayHello on the object obj:
obj.sayHello();
* Explanation:
* Option A: Obj.sayHello; is incorrect syntax. The correct syntax is obj.sayHello();.
* Option B: Window.sayHello(); is incorrect because the method is defined in the obj object, not the window object.
* References:
* MDN Web Docs - Functions
* W3Schools - JavaScript Objects


質問 # 53
Given the following markup and no style sheet:

Which control does the input element render?

  • A. Slider
  • B. Text
  • C. Button
  • D. Drop-down

正解:A

解説:
The type="range" attribute in an <input> element renders a slider control.
* HTML Input Type range:
* Purpose: The range type is used for input fields that should contain a value from a range of numbers.
* Example:
* Given the HTML:
<input id="range" name="range" type="range">
* Explanation:
* This will render as a slider that the user can move to select a value within a range.
* References:
* MDN Web Docs - <input type="range">
* W3Schools - HTML Input Range


質問 # 54
Which property or method requires a minimum of two values to apply?

  • A. It requires a minimum of one value to apply
  • B. It accepts pixel values only.
  • C. It accepts Hex values only
  • D. It requires a minimum of two values to apply.

正解:D

解説:
This question seems to be about a property or method that requires two values. Without additional context, the most common scenario that fits this description is CSS properties that define sizes or positions with two values. Examples include background-position, margin, padding, etc., where both horizontal and vertical values are needed.
References:
* MDN Web Docs on Background Position
* W3C CSS Backgrounds and Borders Module Level 3


質問 # 55
Which layout method causes images to render to small or too large in browser windows of different sizes?

  • A. Relative width
  • B. Fluid
  • C. Liquid
  • D. Fixed width

正解:D

解説:
A fixed-width layout method specifies exact pixel values for widths. This approach does not adapt to different screen sizes, leading to images rendering too small or too large on various devices.
* Fixed Width Layout:
* Definition: Uses specific pixel values for the width of elements.
* Example:
container {
width: 800px;
}
* Issues:
* Lack of Flexibility: Does not scale with the size of the viewport, causing images and other elements to appear incorrectly sized on different screen sizes.
* Comparison:
* Fluid/Liquid: Adapts to the screen size using percentages or other relative units.
* Relative Width: Also adapts using units like em or %.
* References:
* MDN Web Docs - Fixed vs. Fluid Layout
* W3C CSS Flexible Box Layout Module Level 1
Using fixed-width layouts can result in poor user experience across different devices, highlighting the importance of responsive design principles.
Top of Form
Bottom of Form


質問 # 56
Given the following HTML statement:

And the following style:

Which line of the changes the background color of the <div> tag when the width is between 600 pixels and
900 pixels or more than 1, 100 pixels?

  • A.
  • B.
  • C.
  • D.

正解:A

解説:
The given HTML and CSS statements define a class named "example" and use media queries to change the background color of the <div> element based on the screen width. The correct CSS media query to change the background color of the <div> tag when the width is between 600 pixels and 900 pixels or more than 1100 pixels is:Copy code
@media screen and (max-width: 900px) and (min-width: 600px), (min-width: 1100px) { div.example { background: yellow;
}
}
* Understanding Media Queries:
* @media screen: Applies the styles only for screens.
* (max-width: 900px) and (min-width: 600px): Targets screen widths between 600 and 900 pixels.
* , (comma): Acts as an "or" operator in media queries.
* (min-width: 1100px): Targets screen widths greater than or equal to 1100 pixels.
* Option C Explanation:
* This option uses the correct media query syntax to apply the background color change when the screen width is between 600 and 900 pixels or when it is 1100 pixels or more.
References:
* MDN Web Docs on Media Queries
* W3C CSS Media Queries Level 4
The correct CSS media query based on the provided options is:
@media screen and (max-width: 900px) and (min-width: 600px), (min-width: 1100px) { div.example { background: yellow;
}
}
References for Media Queries:
* MDN Web Docs on Using Media Queries
* W3C CSS Media Queries Module Level 4


質問 # 57
A web designer creates the following HTML code:

Which CSS selector applies only to the first line?

  • A. #Welcome
  • B. #Header
  • C. .Welcome
  • D. .header

正解:A

解説:
To apply CSS only to the first line of a particular HTML element, the ID selector #Welcome should be used as per the given HTML structure.
* CSS ID Selector: The ID selector is used to style the element with a specific id.
* Usage Example:
#Welcome {
color: red;
}
In this example, the #Welcome selector will apply the red color style only to the element with id="Welcome".
References:
* MDN Web Docs on ID Selectors
* W3C CSS Specification on Selectors


質問 # 58
Where can users items using the HTML

  • A. From a user's computer to a web page
  • B. From a user's computer to another computer
  • C. From a web page to another web page
  • D. From a web page to a user's computer

正解:A

解説:
Using HTML, users can upload files from their computer to a web page using the <input> element with the type="file" attribute.
* File Upload Input: The <input type="file"> element is used in forms to allow users to select files from their local file system to be uploaded to a server.
* Usage Example:
The <canvas> element in HTML5 is used to render images and graphics dynamically through JavaScript. It is a powerful feature for creating graphics, game visuals, data visualizations, and other graphical content directly in the browser.
* Canvas Element: The <canvas> element is an HTML tag that, with the help of JavaScript, can be used to draw and manipulate graphics on the fly.
* Usage Example:
html
Copy code
<canvas id="myCanvas" width="200" height="100"></canvas>
<script>
var canvas = document.getElementById("myCanvas");
var ctx = canvas.getContext("2d");
ctx.fillStyle = "#FF0000";
ctx.fillRect(0, 0, 200, 100);
</script>
In this example, a red rectangle is drawn on a canvas element.
References:
* MDN Web Docs on <canvas>
* W3C HTML Canvas 2D Context Specification
<form action="/upload" method="post" enctype="multipart/form-data">
<input type="file" name="fileToUpload" id="fileToUpload">
<input type="submit" value="Upload File" name="submit">
</form>
In this example, users can choose a file from their computer and upload it to the specified server endpoint.
References:
* MDN Web Docs on <input type="file">
* W3C HTML Specification on File Upload


質問 # 59
Given the following code:

What is occurring?

  • A. In-line CSS is styling the <h1> tag.
  • B. An event handler is tracking keyboard strokes.
  • C. JavaScript is using the DOM to make a style change.

正解:C

解説:
The given code snippet demonstrates how JavaScript can manipulate the DOM to change the style of an element.
* Code Analysis:
* Given the HTML:
<h1 id="id1">Blog Title</h1>
<button type="button" onclick="document.getElementById('id1').style.color = 'red'">Click Here</button>
* When the button is clicked, the JavaScript code within the onclick attribute changes the color of the h1 element to red.
* Explanation:
* Option A: An event handler tracking keyboard strokes is incorrect because the event handler is tracking a mouse click, not keyboard strokes.
* Option B: JavaScript is using the DOM to make a style change is correct because the onclick attribute contains JavaScript code that modifies the style of the h1 element.
* Option C: In-line CSS is styling the <h1> tag is incorrect because the style change is done via JavaScript, not inline CSS.
* References:
* MDN Web Docs - Document.getElementById()
* W3Schools - JavaScript HTML DOM


質問 # 60
A web page has a section that contains an <article> element. The element is always 10 pixels to the right of its position.
Which type of layout positioning should the <article> element use?

  • A. Fixed
  • B. Static
  • C. Absolute
  • D. Relative

正解:D

解説:
Relative positioning in CSS positions an element relative to its normal position. Using position: relative; allows you to adjust the element's position with the top, right, bottom, or left properties.
* CSS Relative Positioning:
* Syntax:
article {
position: relative;
left: 10px;
}
* Description: Moves the element 10 pixels to the right from its normal position.
* Example:
* Given HTML:
<article>Content</article>
* Given CSS:
article {
position: relative;
left: 10px;
}
* Explanation: The <article> element will be positioned 10 pixels to the right of where it would normally appear.
* References:
* MDN Web Docs - position
* W3C CSS Positioned Layout Module Level 3


質問 # 61
What is an advantage that a mobile has over a mobile app?

  • A. It has full control of the user interface
  • B. It is fully functional offline.
  • C. It is automatically available to all users
  • D. It is automatically awe to access all device capabilities

正解:C

解説:
A mobile website has the advantage of being automatically available to all users without the need for installation. Users can access it through their web browsers on any device with internet connectivity.
* Accessibility: Mobile websites can be accessed by simply entering a URL in a web browser. There is no need to visit an app store and install an application.
* Cross-Platform Compatibility: Mobile websites are designed to work across various devices and platforms, ensuring a broader reach.
* Automatic Updates: Updates to mobile websites are immediately available to users without requiring them to download and install new versions.
References:
* MDN Web Docs on Responsive Web Design
* W3C Mobile Web Application Best Practices


質問 # 62
Which HTML5 attribute specifies where to send the form data for processing a form is submitted?

  • A. Target
  • B. Enctype
  • C. Action
  • D. Method

正解:C

解説:
The action attribute in the <form> element specifies the URL where the form data should be sent for processing when the form is submitted.
* Action Attribute: This attribute defines the endpoint that will handle the submitted form data.
* Usage Example:
<form action="/submit-form" method="post">
<input type="text" name="username">
<input type="submit" value="Submit">
</form>
Here, the form data is sent to the /submit-form URL when submitted.
References:
* MDN Web Docs on <form> action attribute
* W3C HTML Specification on Forms


質問 # 63
Which code segment creates a slider field that accepts a numeric value ranging from 1 through 10?

  • A.
  • B.
  • C.
  • D.

正解:C

解説:
To create a slider field that accepts a numeric value ranging from 1 through 10, the input element with type=" range" should be used. The min and max attributes define the range of acceptable values.
* HTML Input Type range:
* Purpose: The range type is used for input fields that should contain a value from a specified range.
* Attributes:
* type="range": Specifies that the input field should be a slider.
* min="1": Sets the minimum acceptable value.
* max="10": Sets the maximum acceptable value.
* Example:
* Given the HTML:
<input type="range" name="sat-level" min="1" max="10">
* Options Analysis:
* Option A:
<input type="number" name="sat-level" max="10">
* This creates a numeric input field, not a slider.
* Option B:
<input type="range" name="sat-level" min="1" max="10">
* This is the correct option that creates a slider field with the specified range.
* Option C:
<input type="number" name="sat-level" min="1" max="10">
* This creates a numeric input field, not a slider.
* Option D:
<input type="range" name="sat-level" max="10">
* This creates a slider but lacks the min attribute, so it doesn't fully meet the requirement.
* References:
* MDN Web Docs - <input type="range">
* W3Schools - HTML Input Range
By using the correct attributes, the slider field will allow users to select a value between 1 and 10.


質問 # 64
What is a common technique to ensure users can access all content on a mobile web page?

  • A. Targeted site content
  • B. Access to multiple link layers
  • C. A link to the full site
  • D. Navigation links requiring scrolling

正解:C

解説:
Providing a link to the full site on a mobile web page is a common technique to ensure users can access all content if they find the mobile version limiting.
* Advantages:
* Access to Full Functionality: Users can switch to the desktop version if they need features not available on the mobile site.
* User Control: It gives users the choice to view the site in a layout they are more comfortable with.
* Other Options:
* A. Access to multiple link layers: This does not directly address user needs for full site access.
* B. Targeted site content: While important, it does not replace the need for a full site link.
* D. Navigation links requiring scrolling: This can worsen the user experience on mobile devices.
* References:
* Google Developers - Mobile Site Design


質問 # 65
Which method retrieves periods updates about the geographic location of a user:

  • A. WatchPosition
  • B. ClearWatch
  • C. GetContext
  • D. getCurrentPosition

正解:A

解説:
The watchPosition method in the Geolocation API is used to get periodic updates about the geographic location of a user.
* watchPosition Method: This method calls the provided callback function with the user's current position as the device's location changes.
* Usage Example:
navigator.geolocation.watchPosition(function(position) {
console.log("Latitude: " + position.coords.latitude + ", Longitude: " + position.coords.longitude);
});
In this example, the watchPosition method continuously logs the user's latitude and longitude to the console as the position changes.
References:
* MDN Web Docs on watchPosition
* W3C Geolocation API Specification


質問 # 66
......

Web-Development-Applications問題集100パー合格保証には最新のサンプル:https://jp.fast2test.com/Web-Development-Applications-premium-file.html

あなたを合格させる試験には100%確認済みWeb-Development-Applications試験問題:https://drive.google.com/open?id=1WduoDCg8fwsCj4DzLwhqqTNXnShaajqf


弊社を連絡する

我々は12時間以内ですべてのお問い合わせを答えます。

我々の働いている時間: ( GMT 0:00-15:00 )
月曜日から土曜日まで

サポート: 現在連絡 

English Deutsch 繁体中文 한국어