CodeGym
Promotion
CodeGym University
Learning
Courses
Tasks
Surveys & Quizzes
Games
Help
Schedule
Community
Users
Forum
Chat
Articles
Success stories
Activity
Reviews
Subscriptions
Light theme
Question
  • Reviews
  • About us
Start
Start learning
Start learning now
  • All questions
CodeGym/Help with Java Tasks/Why is the 5th condition not full filled
Abhijeet Ranaut
Level 2
Mumbai
  • 1/22/19
  • 1588views
  • 1comment

Why is the 5th condition not full filled

Question about the task Don't feel like it? Do it anyway.
Java Syntax,  Level 1,  Lesson 8
Resolved

Write a program that displays: "If you feel like it, do the task. If you don't feel like it, do it anyway" 16 times.

Requirements:
  • The program should output text.
  • The text should begin with "If you feel like it".
  • The text should end with "anyway".
  • The text should consist of 16 lines.
  • The displayed text must match the task conditions.
package com.codegym.task.task01.task0126; /* Don't feel like it? Do it anyway. */ public class Solution { public static void main(String[] args) { System.out.println("If you feel like it"); System.out.println("if you feel like it "); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("if you feel like it"); System.out.println("jcydtdu anyway"); } }
0
Comments (1)
  • Popular
  • New
  • Old
You must be signed in to leave a comment
Michael Martin
Level 2 , Arlington, United States
22 January 2019, 05:46
You should have 16 lines of:
System.out.println("If you feel like it, do the task. If you don't feel like it, do it anyway");
+1
Learn
  • Registration
  • Java Course
  • Help with Tasks
  • Pricing
  • Java Syntax
Community
  • Users
  • Articles
  • Forum
  • Chat
  • Success Stories
  • Activity
  • Affiliate Program
Company
  • About us
  • Contacts
  • Reviews
  • Press Room
  • CodeGym for EDU
  • FAQ
  • Support
CodeGym CodeGym is an online course for learning Java programming from scratch. This course is a perfect way to master Java for beginners. It contains 1200+ tasks with instant verification and an essential scope of Java fundamentals theory. To help you succeed in education, we’ve implemented a set of motivational features: quizzes, coding projects, content about efficient learning, and a Java developer’s career.
Follow us
Interface language
English
Deutsch Español हिन्दी Français Português Polski বাংলা 简体中文 मराठी தமிழ் Italiano Bahasa Indonesia 繁體中文 Nederlands 日本語 한국어 Bulgarian Danish Hungarian Basa Jawa Malay Norwegian Romanian Swedish Telugu Thai Українська Filipino Turkish Azərbaycan Русский Vietnamese
Programmers Are Made, Not Born © 2026 CodeGym
MastercardVisa
Programmers Are Made, Not Born © 2026 CodeGym