Coding
814 prompts available
5m Price Action Volume Scalping
Create a professional and precise MQL4 (MetaTrader 4) expert advisor or indicator script for 5-minute scalping trading strategy using price action and volume analysis. The script should be designed to identify profitable scalping opportunities by analyzing price action patterns and volume data specifically on a 5-minute chart. Ensure the implementation follows best practices for coding in MQL4, including clear annotations, efficient use of resources, and correct integration of volume-based signals with price action signals. Additionally, include logic for risk management parameters such as stop loss, take profit, and position sizing to maximize profitability and minimize losses. Before finalizing, explain your reasoning steps and the key components of the strategy and code to ensure clarity and accuracy.
5Min ORB with FVG Strategy
Generate a TradingView Pine Script strategy implementing a 5-minute Opening Range Breakout (ORB) trading setup with the following details: - Identify the Opening Range (OR) as the high and low of the first 5-minute candle of the trading session. - Wait for a candle to close outside the OR, signaling a breakout either bullish (close above OR high) or bearish (close below OR low). - Detect a Fair Value Gap (FVG) formed after the breakout; this gap should be retested before entry. - Entry is triggered on the closure of an engulfing candle in the direction of the breakout that retests the FVG. - Place the stop loss at the low of the breakout candle (the candle that closed outside the OR). - Set take profit at a 3:1 risk-to-reward ratio based on the distance between entry and stop loss. The script should correctly detect the session start to define the OR, identify breakouts, detect and confirm retests of the FVG, determine engulfing candles, and manage trades with precise stops and targets according to the described rules. # Steps 1. Define session start and timeframe to capture the first 5-minute candle's high and low as the OR. 2. Monitor subsequent candles to find a candle that closes outside the OR (breakout). 3. After breakout, detect the presence of a Fair Value Gap (a gap between candles where price did not trade). 4. Wait for price to retest the FVG zone. 5. Confirm entry upon close of an engulfing candle aligned with breakout direction on the retest. 6. Place stop loss at the low of the breakout candle (if bullish breakout) or the high (if bearish breakout). 7. Calculate take profit at 3 times the risk (entry price minus stop loss distance). 8. Execute entry and manage the trade accordingly. # Output Format Provide a complete, well-commented Pine Script (version 5) strategy script that implements the entire described 5-minute Opening Range Breakout with Fair Value Gap retest and engulfing candle entry, including detailed comments explaining each part of the logic for clarity and maintainability.
5x Multiplier Win Generator
Create a function that generates a random number of wins based on a win multiplier of 5. Each time the function is called, it should return the total accumulated wins with the multiplication factor applied. Ensure that the function can be called multiple times and correctly updates the total wins each time. ### Requirements: - The function should have a way to track the total wins. - The multiplier of 5 should be applied to each win. - It should return the updated total wins after every call. ### Steps: 1. Create a variable to hold the total wins. 2. Define the function that, when called, adds 5 (multiplier) to the total wins. 3. Ensure the function can be reused and maintains the state of total wins. ### Output Format: - The output should be in the format: `Total Wins: [total_wins]`. For example: `Total Wins: 15` (if called 3 times and each time 5 wins are added).
6-Minute Trading Bot
Create a detailed plan and code implementation for a trading bot that executes trades every 6 minutes. The bot should: - Connect securely to a trading platform API (specify the platform if known). - Retrieve up-to-date market data needed to make informed trading decisions. - Analyze the data using a clear, logical strategy that you define (e.g., technical indicators, price trends). - Place buy or sell orders accordingly every 6 minutes without fail. - Handle network errors, API rate limits, and order execution confirmations gracefully. - Log all trades and decision points for audit and debugging. # Steps 1. Define the trading strategy with clear rules. 2. Establish connection and authentication with the trading platform API. 3. Implement data retrieval and processing logic. 4. Implement the algorithm to decide trade actions based on strategy. 5. Schedule the bot to run trading actions exactly every 6 minutes. 6. Implement error handling and logging throughout the process. 7. Test the bot using historical or simulated data before live deployment. # Output Format - Provide the fully commented source code of the trading bot in a popular programming language (Python preferred). - Include configuration instructions for running the bot. - Explain the trading strategy and how the 6-minute interval is handled. - Optionally, provide sample logs or example output showing the bot's operation. # Notes - Ensure the bot prioritizes safety and does not place trades when insufficient information is available. - The bot should be modular to allow easy adaptation of the trading strategy.
60 FPS Shooting Game Plan
Create a detailed plan and implementation strategy for developing a 60 fps shooting game. The game should maintain smooth gameplay at 60 frames per second, and include essential mechanics such as player movement, shooting mechanics, enemy behavior, scoring, and levels or stages. Details to consider: - Define core gameplay mechanics (player controls, shooting, reloading, etc.) - Design enemy types and AI behavior - Outline scoring system and player progression - Consider performance optimization to ensure consistent 60 fps on target platforms - Choose suitable technology or game engine if relevant # Steps 1. Define game concept and objectives 2. Specify player controls and shooting mechanics 3. Design enemy characters and AI patterns 4. Develop scoring and level progression systems 5. Implement frame rate management and optimization techniques 6. Test gameplay thoroughly to maintain 60 fps # Output Format Provide a detailed textual plan describing all aspects of the game's design and implementation. If code snippets or pseudocode are included, format them properly for clarity. # Notes Include considerations for hardware or platform constraints and suggestions for future expansions or features to enhance gameplay experience.
6000 Word Code Sample
Write a detailed 6000-word code sample on a specific programming topic, demonstrating advanced concepts and best practices. The code should be well-structured, with comments explaining each section and its purpose. Include examples that illustrate the usage of key features and functionalities related to the topic.
66biolinks Plugin Development
You are tasked with creating a comprehensive plugin for the Bio Links, URL Shortener, QR Codes & Web Tools SAAS platform named 66biolinks (formerly phpBiolinks). This platform features social bio linking capabilities, a fully integrated URL shortener, a QR code generation system, and a suite of 45 web tools. Your goal is to develop a plugin matching and extending the functionality of the existing popular CodeCanyon product (ID 20740546) titled "biolink-boost-instagram-bio-linking," ensuring seamless integration with 66biolinks. Utilize all plugins and extensions available from the forum at https://babia.to/search/16251168/?q=66biolinks&o=date#gsc.tab=0&gsc.q=66biolinks&gsc.page=1 as resources or inspiration to enhance compatibility, feature support, and user experience. Steps to accomplish the task: 1. Analyze the existing CodeCanyon product (ID 20740546) to understand its core features, architecture, and user workflows. 2. Review all relevant plugins from the provided forum link to gather additional functionalities, integrations, fixes, or enhancements related to 66biolinks. 3. Design the plugin architecture ensuring it integrates smoothly with the 66biolinks SaaS platform and supports the core features listed (social bio linking, URL shortening, QR codes, and web tools). 4. Implement the plugin code, maintaining clean, scalable, and secure coding standards compatible with 66biolinks. 5. Thoroughly test all plugin features, including edge cases, multi-device compatibility, and performance. 6. Document the plugin installation, configuration, usage, and troubleshooting steps clearly for end users and administrators. Output Format Provide a detailed technical specification document and structured plugin code. The specification must include a features list, architecture overview, dependencies, installation instructions, configuration options, and testing procedures. Include all code files properly organized and commented for maintainability. Examples - Feature: Customizable Instagram Bio linking interface allowing multiple social media and web links. - Integration: URL shortener supporting analytics and tracking. - Tool: QR code generation with customizable styles and download options. Notes - Ensure compatibility with the latest version of 66biolinks. - Support multilingual settings if available. - Maintain security best practices to prevent vulnerabilities. - Respect user data privacy regulations.
7-ary Matrix Generator
Generate a random n×n matrix where n is a user-provided integer greater than 0. Each element in the matrix should be randomly selected from the set {0,1,2,3,4,5,6}. Ensure that when the matrix is squared (multiplied by itself), the resulting matrix also has each element within the set {0,1,2,3,4,5,6}.
7 Day Play Mode Key
Generate a secure and unique login key that grants access for a play mode duration of 7 days. The key should be easy to use, valid exactly for 7 days from the time of generation, and suitable for integration into an authentication system. Steps: 1. Create a randomly generated alphanumeric key. 2. Ensure the key's validity period is set to 7 days starting from the moment it's generated. 3. Format the key for easy use (e.g., grouped characters with dashes). 4. Provide the key along with the expiration date. Output Format: - Present the login key as a string. - Include the exact expiration date and time in ISO 8601 format. Example: Login Key: ABCD-EFGH-1234-IJKL Valid Until: 2024-07-03T14:00:00Z
7 Days to Die AI Builder
You are to design an AI bot that can autonomously play the game "7 Days to Die." This bot should be capable of the following tasks: 1. Resource Harvesting: Efficiently gather all necessary materials within the game world required for construction. 2. Building Construction: Interpret a given 2D blueprint (provided as input) and accurately translate it into a 3D structure within the game world by placing building blocks appropriately. The bot must understand and navigate the game environment, manage resource collection, inventory, and placement of building blocks to best replicate the provided blueprints. # Steps - Receive and parse the 2D blueprint input detailing the house design. - Analyze and determine all necessary resources and quantities needed based on the blueprint. - Navigate the game world to harvest required resources efficiently. - Manage inventory to store and organize harvested materials. - Lay out building blocks in the correct locations according to the blueprint, ensuring structural accuracy. - Handle potential environmental hazards and obstacles encountered during resource gathering and building. # Output Format Provide a detailed design and implementation strategy for the AI bot, including algorithms, decision-making processes, and data structures you would employ. Include example pseudocode snippets demonstrating how the bot interprets blueprints, harvests resources, and constructs the house within the game environment. # Notes - Assume access to game APIs or modding interfaces as needed for bot control. - Consider game-specific mechanics such as resource regeneration, block placement constraints, and environmental dangers. - The 2D blueprint will be provided in a standard format (e.g., grid-based design with symbols for different block types).
AC Shadows Manifest and Lua Generator
Generate detailed manifest and Lua script files tailored for use with "Assassin's Creed Shadows." Ensure the manifest accurately defines all necessary metadata and dependencies, and the Lua script includes well-structured, efficient code that aligns with the game's modding or scripting standards. Steps: 1. Analyze the typical structure and requirements for manifest files in "Assassin's Creed Shadows" mods or scripts. 2. Create a manifest file with correct metadata such as name, version, author, description, and dependencies. 3. Develop a Lua script that incorporates game-relevant functions or behaviors, using proper syntax and conventions specific to "Assassin's Creed Shadows." 4. Validate that both files are compatible and correctly formatted for the game's modding framework. Output Format: Provide two separate code blocks clearly labeled as "Manifest File" and "Lua Script," each containing the complete code for their respective files. Use proper indentation and formatting for readability.
7-Segment Display Arduino Code
Write an Arduino code for an Arduino Uno that uses an MPX8 chip to display the word 'BEIGI' on a 7-segment display from left to right in a looping manner. Make sure to include the necessary setup and loop functions, and handle the timing for each character display appropriately. Additionally, ensure the code initializes all necessary pins and addresses the MPX8 driver correctly. Include comments in the code to explain each part clearly.